You can enable incremental compilation of the MSBuild BizTalk project with a few very simple changes. Basically, you need to override the two goals that are defined in the file BizTalkCommon.targets.
These targets can be overridden in your own .btproj files and do not require changing the source .targets file that comes with BizTalk.
how
First, create your own .targets file to place your settings, for example BizTalkCustom.targets:
<Import Project="$(MSBuildExtensionsPath)\Microsoft\BizTalk\BizTalkC.targets" />
<Target Name="SecondPass" Condition="$(SecondBuild)!=true and $(TempAssemblyOnly)!=true and @(XLang)!=''">
<MSBuild Projects="$(MSBuildProjectFile)" Properties="SecondBuild=true" />
</Target>
<Target
Name="CompileODX"
Condition="$(SecondBuild)==true"
Inputs="@(XLang);$(MSBuildAllProjects);$(ClrTypesAssembly)"
Outputs="$(BuildDone)">
<Delete Files="@(IntermediateAssembly)" />
<Delete Files="@(CSharpOutputFromXLang)" />
<XLangTask XLangItems="@(XLang)"
ProjectReferences="@(ReferencePath)"
WarningLevel="$(WarningLevel)"
BpelCompliance="$(BpelCompliance)"
DefineConstants="$(DefineConstants)"
TreatWarningsAsErrors="$(TreatWarningsAsErrors)"
TempAssembly="$(ClrTypesAssembly)"
OutputDirectory="$(XLangOutputPath)">
</XLangTask>
</Target>
Then replace the last statement Importin the .btproj file:
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(MyCustomExtensions)\BizTalkCustom.targets" />
How it works
BizTalk Server - . , , .
, , BizTalkCommon.targets file. , :
SecondPass Target Condition. , , .
, Orchestrations, SecondPass Target , . , CompileODX Target , . Delete SecondPass Target CompiledODX.
, .