PDA

View Full Version : How to customize the Output Directory in the Make VS2005 step?


abcdetech
07-09-2009, 01:46 PM
Hi,

I have a question about updating the Output Directories in the Make VS steps.

Let's say my VS projects have multiple configurations such as:
Debug
Release
DebugMT
ReleaseMT
.......

I want to build my projects in ALL configurations.
I want to have my outputs to be sorted out accordign to a configutation in which they were built:

c:\WORK_ROOT\Debug\bin\ABC.dll
c:\WORK_ROOT\Release\bin\ABC.dll
c:\WORK_ROOT\DebugMT\bin\ABC_MT.dll
c:\WORK_ROOT\ReleaseMT\bin\ABC_MT.dll

is there a variable for Configuration? So I can specify my Output Directory as:

%WORK_ROOT%\$Config\bin

Does VisualBuildPro generate any variable which corresponds to a current building configuration ($Config) ? See attachment for more info.

Thank you

kinook
07-09-2009, 06:06 PM
Something like

c:\WORK_ROOT\$(ConfigurationName)\bin

in the Output directory field on the Project/Solution tab of the Make VS.NET action should work.

http://www.kinook.com/VisBuildPro/Manual/vsnetprojectsolutiontab.htm

http://msdn.microsoft.com/en-us/library/c02as0cs.aspx

abcdetech
07-31-2009, 10:10 AM
thank you.

the Output directory field on the Project/Solution tab works perfectly for me, very useful feature.

I have another similar question.

How do I do a similar thing to Librarian Output File?

What I want to do, I want to replace in all .vcproj files :

<Tool Name="VCLibrarianTool" OutputFile=".\debug\LibraryName.lib"/>

with

<Tool Name="VCLibrarianTool" OutputFile="$(OutDir)\LibraryName.lib"/>

In other words I want to keep developer's library file name but output into my desired location. To replace ".\debug\LibraryName.lib" with $(OutDir)\LibraryName.lib"

What is the best way to do it?

I don't see such ability in the Make VS steps. I tried the Write XML file (but it doesn't allow a replace operation)

thank you

kinook
07-31-2009, 11:22 AM
See attached sample, and also see http://www.kinook.com/VisBuildPro/Manual/regex.htm for more help with regular expressions.