|
3 | 3 |
|
4 | 4 | <Import Project="$(MSBuildThisFileDirectory)..\..\dir.traversal.targets" />
|
5 | 5 |
|
6 |
| - <PropertyGroup Condition="'$(OfficialBuildId)' != ''"> |
7 |
| - <!-- During an official build, only build identity packages in the AllConfigurations build --> |
8 |
| - <BuildIdentityPackage Condition="'$(BuildIdentityPackage)' == '' AND '$(OS)' == 'Windows_NT' AND '$(BuildArch)' == 'x64'">true</BuildIdentityPackage> |
| 6 | + <PropertyGroup Condition="'$(BuildIdentityPackage)' == ''"> |
| 7 | + <BuildIdentityPackage>true</BuildIdentityPackage> |
| 8 | + |
| 9 | + <!-- Used to determine if we should build some packages only once across multiple official build legs. |
| 10 | + For offline builds we still set OfficialBuildId but we need to build all the packages for a single |
| 11 | + leg only, so we also take DotNetBuildOffline into account. --> |
| 12 | + <BuildingAnOfficialBuildLeg Condition="'$(OfficialBuildId)' != '' AND '$(DotNetBuildOffline)' != 'true'">true</BuildingAnOfficialBuildLeg> |
| 13 | + |
| 14 | + <!-- During an official build, only build identity packages on windows x64 legs --> |
| 15 | + <BuildIdentityPackage Condition="'$(BuildingAnOfficialBuildLeg)' == 'true' AND ('$(OS)' != 'Windows_NT' OR '$(BuildArch)' != 'x64')">false</BuildIdentityPackage> |
9 | 16 | </PropertyGroup>
|
10 | 17 |
|
11 | 18 | <Target Name="FilterProjects" BeforeTargets="Build">
|
12 | 19 | <Error Condition="'$(PackageRID)' == ''" Text="'PackageRID' property must be specified."/>
|
13 | 20 |
|
14 | 21 | <!-- Only build packages for current RID or non-RID-specific -->
|
15 |
| - <ItemGroup Condition="$(BuildIdentityPackage)!='true'"> |
| 22 | + <ItemGroup> |
16 | 23 | <_projectsToBuild Include="@(Project)" Condition="'%(Project.PackageTargetRuntime)' == '$(PackageRID)'" />
|
17 | 24 | </ItemGroup>
|
18 | 25 |
|
19 |
| - <ItemGroup Condition="$(BuildIdentityPackage)=='true'" > |
20 |
| - <_projectsToBuild Include="@(Project)" Condition="'%(Project.PackageTargetRuntime)' == '$(PackageRID)' OR '%(Project.PackageTargetRuntime)' == ''" /> |
| 26 | + <ItemGroup Condition="'$(BuildIdentityPackage)' == 'true'"> |
| 27 | + <_projectsToBuild Include="@(Project)" Condition="'%(Project.PackageTargetRuntime)' == ''" /> |
21 | 28 | </ItemGroup>
|
22 | 29 |
|
23 | 30 | <ItemGroup>
|
|
0 commit comments