February 4th, 2013, 02:02 AM
MSBUILD commands for C++ VS2010
I'm working on project migration in which a VS2003 C++ project is migrated to VS2010. The VS2003 project was built using NMAKE whereas the VS2010 project should use MSBUILD.
Based on the NMAKE commands I'm trying to create the respective MSBUILD file.
Below is a "compiling and linking command" in NMAKE file.
cl /GX /MD /Zm800 /I..\..\include /I"$(PBASE_ANCHOR)\hs_regex\include" $(DEFINE_FORCE_BUILD_VERSION) /Fecode_generator.exe code_generator.cpp /link /LIBPATH:"$(PBASE_ANCHOR)\hs_regex\lib" hs_regex_static.lib
I'm trying to write its corresponding msbuild command.
<ClInclude Include="$(PBASE_ANCHOR)\hs_regex\lib\hs_regex.lib" />
<ClInclude Include="$(PBASE_ANCHOR)\hs_regex\lib\hs_regex_static.lib" />
<ClCompile Include="$(CODEGEN_DIR)\uff_code_generator.cpp" />
<ClCompile Include="$(CODEGEN_DIR)\cg_bootstrap.cpp" />
<Target Name="build" >
<MSBuild Projects="@(ClCompile)" Targets="$(DEVENV_OPTION)" Properties="Configuration=$(CONFIGURATION)"/>
This is what I have written to compile-n-link the code_generator.cpp and \cg_bootstrap.cpp.
Am I missing any targets or properties to get the .exe file, .obj file for code_generator.cpp and cg_bootstrap.cpp??
Any help would be appreciated.. :-)
Tags for this Thread
Click Here to Expand Forum to Full Width
This is a CodeGuru survey question.