Make Native components a non-required part for build.cmd, fix IIS native code check (#10435)

This commit is contained in:
Justin Kotalik 2019-05-25 15:20:26 -07:00 committed by GitHub
parent 2d1c14d5a9
commit a20ddd8374
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 6 additions and 5 deletions

View File

@ -328,7 +328,7 @@ jobs:
agentOs: Windows
isTestingJob: true
buildScript: ./eng/scripts/cibuild.cmd
buildArgs: -test "/p:SkipIISBackwardsCompatibilityTests=true /p:SkipIISTests=true /p:SkipIISExpressTests=true /p:SkipIISForwardsCompatibilityTests=true /p:RunTemplateTests=false /p:BuildSiteExtensions=false"
buildArgs: -test -BuildNative "/p:SkipIISBackwardsCompatibilityTests=true /p:SkipIISTests=true /p:SkipIISExpressTests=true /p:SkipIISForwardsCompatibilityTests=true /p:RunTemplateTests=false /p:BuildSiteExtensions=false"
beforeBuild:
- powershell: "& ./src/Servers/IIS/tools/UpdateIISExpressCertificate.ps1; & ./src/Servers/IIS/tools/update_schema.ps1"
displayName: Setup IISExpress test certificates and schema

View File

@ -15,7 +15,7 @@ jobs:
agentOs: Windows
timeoutInMinutes: 240
steps:
- script: .\build.cmd -all -ci /t:Helix /p:IsHelixJob=true /bl:$env:BUILD_SOURCESDIRECTORY\artifacts\log\SendToHelix.binlog
- script: .\build.cmd -all -ci /p:BuildNative=true /t:Helix /p:IsHelixJob=true /bl:$env:BUILD_SOURCESDIRECTORY\artifacts\log\SendToHelix.binlog
displayName: Run build.cmd helix target
env:
SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops

View File

@ -198,7 +198,7 @@
<!-- Projects which reference Microsoft.AspNetCore.Mvc.Testing should import this targets file to ensure dependency .deps.json files are copied into test output. -->
<MvcTestingTargets>$(MSBuildThisFileDirectory)src\Mvc\Mvc.Testing\src\Microsoft.AspNetCore.Mvc.Testing.targets</MvcTestingTargets>
<!-- IIS native projects can only be built on Windows for x86 and x64. -->
<BuildIisNativeProjects Condition="'$(BuildNative)' != 'false' AND '$(TargetOsName)' == 'win' AND ('$(TargetArchitecture)' == 'x86' OR '$(TargetArchitecture)' == 'x64')">true</BuildIisNativeProjects>
<BuildIisNativeProjects Condition="'$(BuildNative)' == 'true' AND '$(TargetOsName)' == 'win' AND ('$(TargetArchitecture)' == 'x86' OR '$(TargetArchitecture)' == 'x64')">true</BuildIisNativeProjects>
<!-- This property is shared by several projects to layout the AspNetCore.App targeting pack for installers -->
<TargetingPackLayoutRoot>$(ArtifactsObjDir)TargetingPack.Layout\$(Configuration)\</TargetingPackLayoutRoot>
<!-- This property is shared by several projects to layout the AspNetCore.App shared framework for installers -->

View File

@ -258,13 +258,12 @@ elseif ($Projects) {
}
# When adding new sub-group build flags, add them to this check.
elseif((-not $BuildNative) -and (-not $BuildManaged) -and (-not $BuildNodeJS) -and (-not $BuildInstallers) -and (-not $BuildJava)) {
Write-Warning "No default group of projects was specified, so building the 'managed' and 'native' subsets of projects. Run ``build.cmd -help`` for more details."
Write-Warning "No default group of projects was specified, so building the 'managed' subsets of projects. Run ``build.cmd -help`` for more details."
# This goal of this is to pick a sensible default for `build.cmd` with zero arguments.
# Now that we support subfolder invokations of build.cmd, we will be pushing to have build.cmd build everything (-all) by default
$BuildManaged = $true
$BuildNative = $true
}
if ($BuildInstallers) { $MSBuildArguments += "/p:BuildInstallers=true" }

View File

@ -34,6 +34,7 @@
<BuildManaged>true</BuildManaged>
<BuildNodeJS>true</BuildNodeJS>
<BuildJava>true</BuildJava>
<BuildIisNativeProjects Condition="'$(TargetOsName)' == 'win' AND ('$(TargetArchitecture)' == 'x86' OR '$(TargetArchitecture)' == 'x64')">true</BuildIisNativeProjects>
</PropertyGroup>
<!-- These projects are always excluded, even when -projects is specified on command line. -->

View File

@ -37,6 +37,7 @@
</PropertyGroup>
<!-- JAVA -->
<!-- https://github.com/aspnet/AspNetCore-Internal/issues/2555 -->
<Message Importance="High" Text="Ensuring JAVA is available" />
<Exec Command="java -version" />
<Message Importance="High" Text="JAVA is available on the PATH" />