|
#1
|
|||
|
|||
Building with sln specific xml file
Hi,
I have my own build.xml file which works fine at the visual studio command prompt and compiles all the projects, however I would like to incorporate this in VisualBuild using MSBuild action, is it possible , if you do hve an example this will be really helpful. Best |
#2
|
|||
|
|||
In the MSBuild action, specify the build.xml file in the Project file field on the Project tab, and the vcvarsall.bat file (as called by the VS Command Prompt) in the Command to run before main command field on the Advanced tab.
http://www.kinook.com/VisBuildPro/Ma...ildprojtab.htm http://www.kinook.com/VisBuildPro/Ma...dvancedtab.htm |
#3
|
|||
|
|||
THanks, the build.xml i am using complies all the projects fine when used after initiating "Visual Studio 2008 Command prompt" manually but when I use the same build.xml with the MSBUILD in visualbuild (as mentioned by you earlier, I get the message that "OUTPUTDIR is not specified for one of the projects"
?? |
#4
|
|||
|
|||
Take it in steps to ensure everything is setup the same in Visual Build.
1) Run Visual Build from the VS 2008 Command Prompt (start VisBuildPro<enter>), add a Run Program step that makes the same msbuild call as done manually (also set the Start in field to the working folder of the Command Prompt), and build. 2) Add a Set Current Dir step to set the build dir to the working folder of the command prompt, and following that, add a MSBuild step to call the build.xml (select any option or add flags as needed to match the manual msbuild call), and rebuild. 3) Add the vcvarsall.bat call to the MSBuild step as mentioned previously to avoid needing to start Visual Build from the VS 2008 Command Prompt, start Visual Build from a shortcut and build the project. |
#5
|
|||
|
|||
I am sorry I am a bit confused, you want me to run step 1 with setting MSBUILD call to my Build.xml? or to set environment vs 2008? bat file?
Also Am i adding "set current dir" right after step 2? what does working folder imply here? where am I adding call to vcvarsall.bat? I am sorry for the confusion.. Quote:
|
#6
|
|||
|
|||
The first step would be to reproduce your msbuild call within Visual Build via a Run Program action (starting Visual Build from the VS 2008 command prompt to replicate the environment it initializes).
The second step would be to convert this to a MSBuild step in Visual Build, preceded by a Set Current Dir step to set the working folder (still starting from the VS 2008 command prompt). The third step would be to call the vcvarsall.bat (what the Visual Studio 2008 Command Prompt does) in the MSBuild step's Command to run before main command field on the Advanced tab, to setup the environment within the build instead of relying on the VS command prompt. |
#7
|
|||
|
|||
Quote:
|
|
|