Skip to content

Commit

Permalink
Build corelib as part of libraries build. (dotnet#34664)
Browse files Browse the repository at this point in the history
* simplify libraries build dependencies.

* FIx depends for tests

* Fix artifact name for webAssembly

* try building corelib during libraries build.

* small typo

* Merge coreclr+libraries build scripts

* update scripts based on new refactor

* fix script error

* dont build corelib for mono or testbuilds

* Handle webassembly case

* fix allconfigurations build

* remove separate corelib job

* remove corelib jobs from pipelines

* delete build-corelib-job

* PR feedback

* remove special case for webassembly

now that its dependent on the mono runtimeFlavor
  • Loading branch information
mangod9 authored Apr 11, 2020
1 parent ca1a684 commit 38c2d55
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 211 deletions.
15 changes: 0 additions & 15 deletions eng/pipelines/common/build-coreclr-and-libraries-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,6 @@ parameters:
pool: ''

jobs:
- template: /eng/pipelines/coreclr/templates/build-corelib-job.yml
parameters:
buildConfig: ${{ parameters.buildConfig }}
archType: ${{ parameters.archType }}
osGroup: ${{ parameters.osGroup }}
osSubgroup: ${{ parameters.osSubgroup }}
container: ${{ parameters.container }}
testGroup: ${{ parameters.testGroup }}
crossrootfsDir: ${{ parameters.crossrootfsDir }}
timeoutInminutes: ${{ parameters.timeoutInMinutes }}
signBinaries: ${{ parameters.signBinaries }}
stagedBuild: ${{ parameters.stagedBuild }}
variables: ${{ parameters.variables }}
pool: ${{ parameters.pool }}

- template: /eng/pipelines/coreclr/templates/build-job.yml
parameters:
buildConfig: ${{ parameters.buildConfig }}
Expand Down
11 changes: 0 additions & 11 deletions eng/pipelines/coreclr/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,6 @@ jobs:
#
- template: /eng/pipelines/common/checkout-job.yml

#
# Checked Corelib builds
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/coreclr/templates/build-corelib-job.yml
buildConfig: checked
platformGroup: all
jobParameters:
testGroup: outerloop

#
# Debug builds
#
Expand Down
107 changes: 0 additions & 107 deletions eng/pipelines/coreclr/templates/build-corelib-job.yml

This file was deleted.

11 changes: 5 additions & 6 deletions eng/pipelines/libraries/base-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,16 +96,15 @@ jobs:
- _runtimeArtifactName: ''
- _runtimeDownloadPath: ''
- _runtimeArtifactsPathArg: ''
- _runtimeConfigurationArg: ''

- ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}:
- _runtimeDownloadPath: '$(Build.SourcesDirectory)/artifacts/transport/${{ parameters.runtimeFlavor }}'
# Download corelib dependencies for coreclr libraries and not test
- ${{ if and(eq(parameters.runtimeFlavor, 'coreclr'), eq(parameters.testScope, '')) }}:
- _runtimeArtifactName: 'CoreLib_${{ parameters.osGroup }}${{ parameters.osSubgroup }}_${{ parameters.archType }}_${{ parameters.liveRuntimeBuildConfig }}'
- _runtimeConfigurationArg: -rc ${{ parameters.liveRuntimeBuildConfig }}
# Download full product dependencies for mono or test
- ${{ if or(ne(parameters.runtimeFlavor, 'coreclr'), ne(parameters.testScope, '')) }}:
- _runtimeArtifactName: '$(runtimeFlavorName)Product_${{ parameters.osGroup }}${{ parameters.osSubgroup }}_${{ parameters.archType }}_${{ parameters.liveRuntimeBuildConfig }}'
- _runtimeArtifactsPathArg: ' /p:RuntimeArtifactsPath=$(_runtimeDownloadPath)'
- _runtimeArtifactsPathArg: ' /p:RuntimeArtifactsPath=$(_runtimeDownloadPath)'
- _testRunNamePrefixSuffix: $(runtimeFlavorName)_${{ parameters.liveRuntimeBuildConfig }}

# Windows variables
Expand All @@ -116,7 +115,7 @@ jobs:
- ${{ if ne(parameters.osGroup, 'Windows_NT') }}:
- _buildScript: ./$(_buildScriptFileName)$(scriptExt)

- _buildArguments: -configuration ${{ parameters.buildConfig }} -ci -arch ${{ parameters.archType }} $(_finalFrameworkArg) $(_testScopeArg) $(_runtimeOSArg) $(_msbuildCommonParameters) $(_runtimeArtifactsPathArg) $(_crossBuildPropertyArg)
- _buildArguments: $(_runtimeConfigurationArg) -configuration ${{ parameters.buildConfig }} -ci -arch ${{ parameters.archType }} $(_finalFrameworkArg) $(_testScopeArg) $(_runtimeOSArg) $(_msbuildCommonParameters) $(_runtimeArtifactsPathArg) $(_crossBuildPropertyArg)
- ${{ parameters.variables }}

dependsOn:
Expand All @@ -131,7 +130,7 @@ jobs:
steps:
- template: /eng/pipelines/common/clone-checkout-bundle-step.yml

- ${{ if ne(parameters.liveRuntimeBuildConfig, '') }}:
- ${{ if and(ne(parameters.liveRuntimeBuildConfig, ''), or(ne(parameters.runtimeFlavor, 'coreclr'), ne(parameters.testScope, ''))) }}:
- template: /eng/pipelines/common/download-artifact-step.yml
parameters:
unpackFolder: $(_runtimeDownloadPath)
Expand Down
16 changes: 9 additions & 7 deletions eng/pipelines/libraries/build-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,21 +49,23 @@ jobs:

${{ if ne(parameters.liveRuntimeBuildConfig, '') }}:
dependsOn:
# Use corelib dependencies for coreclr and non test builds
- ${{ if and(eq(parameters.runtimeFlavor, 'coreclr'), eq(parameters.testScope, '')) }}:
- ${{ format('coreclr_corelib_build_{0}{1}_{2}_{3}', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.liveRuntimeBuildConfig) }}
# Use full product dependency for non-coreclr and test builds
- ${{ if or(ne(parameters.runtimeFlavor, 'coreclr'), ne(parameters.testScope, '')) }}:
- ${{ format('{0}_product_build_{1}{2}_{3}_{4}', parameters.runtimeFlavor, parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.liveRuntimeBuildConfig) }}

variables:
- _subset: libs
- _addtionalBuildArguments: ''
- _additionalBuildArguments: ''
- ${{ parameters.variables }}
- ${{ if eq(parameters.osGroup, 'WebAssembly') }}:
- EMSDK_PATH: /usr/local/emscripten
# for coreclr library builds (when not testing) build corelib as well.
- ${{ if and(eq(parameters.runtimeFlavor, 'coreclr'), eq(parameters.testScope, '')) }}:
- _subset: clr.corelib+libs
# Tests only run for 'allConfiguration' and 'net472' build-jobs
- ${{ if eq(parameters.runTests, true) }}:
- _subset: libs+libs.tests
- _addtionalBuildArguments: /p:ArchiveTests=true
- _subset: clr.corelib+libs+libs.tests
- _additionalBuildArguments: /p:ArchiveTests=true

- ${{ parameters.variables }}

Expand All @@ -83,7 +85,7 @@ jobs:
- script: $(_buildScript)
-subset $(_subset)
$(_buildArguments)
$(_addtionalBuildArguments)
$(_additionalBuildArguments)
displayName: Restore and Build Product

- ${{ if eq(parameters.runTests, false) }}:
Expand Down
23 changes: 0 additions & 23 deletions eng/pipelines/libraries/outerloop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,29 +13,6 @@ variables:

jobs:
- template: /eng/pipelines/common/checkout-job.yml

#
# CoreLib Build
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/coreclr/templates/build-corelib-job.yml
buildConfig: release
platforms:
- ${{ if eq(variables['includeWindowsOuterloop'], true) }}:
- Windows_NT_x64
- Windows_NT_x86
- ${{ if eq(variables['includeLinuxOuterloop'], true) }}:
- Linux_x64
- Linux_musl_x64
- ${{ if eq(variables['isFullMatrix'], true) }}:
- Linux_arm
- Linux_arm64
- Linux_musl_arm64
- ${{ if eq(variables['includeOsxOuterloop'], true) }}:
- OSX_x64
jobParameters:
testGroup: innerloop

#
# CoreCLR Build
Expand Down
21 changes: 0 additions & 21 deletions eng/pipelines/runtime-official.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,27 +39,6 @@ stages:
#
- template: /eng/pipelines/common/checkout-job.yml

#
# Build CoreLib
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/coreclr/templates/build-corelib-job.yml
buildConfig: release
platforms:
- OSX_x64
- Linux_x64
- Linux_arm
- Linux_arm64
- Linux_musl_x64
- Linux_musl_arm64
- Windows_NT_x86
- Windows_NT_x64
- Windows_NT_arm
- Windows_NT_arm64
jobParameters:
isOfficialBuild: ${{ variables.isOfficialBuild }}

#
# Build CoreCLR
#
Expand Down
21 changes: 0 additions & 21 deletions eng/pipelines/runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,27 +118,6 @@ jobs:
- eng/pipelines/mono/*
- eng/pipelines/libraries/*

#
# Build CoreLib release
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/coreclr/templates/build-corelib-job.yml
buildConfig: release
platforms:
- OSX_x64
- Linux_x64
- Linux_arm
- Linux_arm64
- Linux_musl_x64
- Linux_musl_arm64
- Windows_NT_x64
- Windows_NT_x86
- Windows_NT_arm
- Windows_NT_arm64
jobParameters:
testGroup: innerloop

#
# Build CoreCLR checked
# Only when CoreCLR is changed
Expand Down

0 comments on commit 38c2d55

Please sign in to comment.