Official Content

This page explains aspects related to compilation using MSBuild instead of CSC.

The benefits of using this mechanism are as follows:

  • Enhanced build & compile performance thanks to parallel compilation.
  • A standard project file is generated, so projects can be opened with Visual Studio too. The solution is named LastBuild.sln and is located under the Target Environment build folder. It includes a solution for every object compiled. Notice the solution file will change on every build process referencing the compiled objects.

New Properties associated with this mechanism

Sample property value

-m /v:quiet /p:Configuration=Debug /p:PlatformTarget=x86 /p:GxExternalReference="MyAPI.dll;MyLibrary.dll"

which indicates:

-m => To compile in parallel using all the processors available. If you compile 10 main objects, those 10 main objects will be compiled in parallel, as long as the processors of the machine allow it. 
/v:quiet => Sets the output to quiet, so that it is similar to the previous mechanism (csc). 
/p:Configuration=Debug => To compile in debug mode (generating .pdb files).
/p:PlatformTarget=x86 => To compile for 32 bits (equivalent to /platform:x86 in csc.exe).
/p:GxExternalReference="MyAPI.dll;MyLibrary.dll" => To include MyAPI.dll and MyLibrary in references (equivalent to /r:bin\MyAPI.dll  /r:bin\MyLibrary.dll in csc.exe).

Note: GeneXus .NET Generator already uses this mechanism as the only one suitable.


This feature is available since GeneXus 16 upgrade 10.

See Also

Last update: November 2023 | © GeneXus. All rights reserved. GeneXus Powered by Globant