Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions eng/pipelines/coreclr/templates/build-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,15 @@ jobs:
${{ else }}:
hostArchType: x64

- ${{ if and(in(parameters.osGroup, 'windows'), eq(parameters.archType, 'x86'), ne(parameters.testGroup, 'clrTools'), eq(parameters.pgoType, '')) }}:
- template: /eng/pipelines/coreclr/templates/crossdac-build.yml
parameters:
archType: arm
osGroup: ${{ parameters.osGroup }}
osSubgroup: ${{ parameters.osSubgroup }}
isOfficialBuild: ${{ parameters.signBinaries }}
hostArchType: x86

- ${{ if and(ne(parameters.compilerName, 'gcc'), ne(parameters.testGroup, ''), ne(parameters.testGroup, 'clrTools'), ne(parameters.disableClrTest, true)) }}:
# Publish test native components for consumption by test execution.
- ${{ if and(ne(parameters.isOfficialBuild, true), eq(parameters.pgoType, '')) }}:
Expand Down
11 changes: 9 additions & 2 deletions eng/pipelines/coreclr/templates/crossdac-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,15 @@ steps:
$availableFiles | %{ cp $_.FullName $targetDir -v }
}

CopyAndVerifyCrossOsAssets -CrossDacDir $(buildMuslDacRootFolderPath) -TargetDir '$(buildMuslDacStagingPath)/${{ parameters.hostArchType }}'
CopyAndVerifyCrossOsAssets -CrossDacDir $(buildLinuxDacRootFolderPath) -TargetDir '$(buildLinuxDacStagingPath)/${{ parameters.hostArchType }}'
$buildMuslDacRootFolderPath = "$(Build.SourcesDirectory)/artifacts/bin/coreclr/alpine.${{ parameters.archType }}.$(buildConfigUpper)"
$buildMuslStagingPath = "$(crossDacArtifactPath)/Linux_musl.${{ parameters.archType }}.$(buildConfigUpper)/${{ parameters.hostArchType }}"

$buildLinuxDacRootFolderPath = "$(Build.SourcesDirectory)/artifacts/bin/coreclr/Linux.${{ parameters.archType }}.$(buildConfigUpper)"
$buildLinuxDacStagingPath = "$(crossDacArtifactPath)/Linux.${{ parameters.archType }}.$(buildConfigUpper)/${{ parameters.hostArchType }}"


CopyAndVerifyCrossOsAssets -CrossDacDir $buildMuslDacRootFolderPath -TargetDir $buildMuslStagingPath
CopyAndVerifyCrossOsAssets -CrossDacDir $buildLinuxDacRootFolderPath -TargetDir $buildLinuxDacStagingPath

Write-Host "Final directory contents:"
ls -R $(crossDacArtifactPath)
Expand Down
12 changes: 0 additions & 12 deletions eng/pipelines/coreclr/templates/xplat-pipeline-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,18 +76,6 @@ jobs:
- name: crossDacArtifactPath
value: $(Build.SourcesDirectory)/artifacts/$(buildCrossDacArtifactName)

- name: buildMuslDacRootFolderPath
value: '$(Build.SourcesDirectory)/artifacts/bin/coreclr/alpine.$(archType).$(buildConfigUpper)'

- name: buildMuslDacStagingPath
value: '$(crossDacArtifactPath)/Linux_musl.$(archType).$(buildConfigUpper)'

- name: buildLinuxDacRootFolderPath
value: '$(Build.SourcesDirectory)/artifacts/bin/coreclr/Linux.$(archType).$(buildConfigUpper)'

- name: buildLinuxDacStagingPath
value: '$(crossDacArtifactPath)/Linux.$(archType).$(buildConfigUpper)'

# We need this because both mono and coreclr build currently depends on CoreClr
- name: coreClrProductArtifactName
value: 'CoreCLRProduct_${{ parameters.pgoType }}_${{ parameters.runtimeVariant }}_$(osGroup)$(osSubgroup)_$(archType)_$(buildConfig)'
Expand Down
15 changes: 12 additions & 3 deletions src/coreclr/build-runtime.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ set __BuildAll=

set __TargetArchX64=0
set __TargetArchX86=0
set __TargetArchArm=0
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Arm argument is necessary to specify linux-arm.

set __TargetArchArm64=0

set __BuildTypeDebug=0
Expand Down Expand Up @@ -86,6 +87,7 @@ if /i "%1" == "--help" goto Usage
if /i "%1" == "-all" (set __BuildAll=1&shift&goto Arg_Loop)
if /i "%1" == "-x64" (set __TargetArchX64=1&shift&goto Arg_Loop)
if /i "%1" == "-x86" (set __TargetArchX86=1&shift&goto Arg_Loop)
if /i "%1" == "-arm" (set __TargetArchArm=1&shift&goto Arg_Loop)
if /i "%1" == "-arm64" (set __TargetArchArm64=1&shift&goto Arg_Loop)

if /i "%1" == "-debug" (set __BuildTypeDebug=1&shift&goto Arg_Loop)
Expand All @@ -99,6 +101,7 @@ REM don't add more, use the - syntax instead
if /i "%1" == "all" (set __BuildAll=1&shift&goto Arg_Loop)
if /i "%1" == "x64" (set __TargetArchX64=1&shift&goto Arg_Loop)
if /i "%1" == "x86" (set __TargetArchX86=1&shift&goto Arg_Loop)
if /i "%1" == "arm" (set __TargetArchArm=1&shift&goto Arg_Loop)
if /i "%1" == "arm64" (set __TargetArchArm64=1&shift&goto Arg_Loop)

if /i "%1" == "debug" (set __BuildTypeDebug=1&shift&goto Arg_Loop)
Expand Down Expand Up @@ -162,7 +165,7 @@ if defined VCINSTALLDIR (

if defined __BuildAll goto BuildAll

set /A __TotalSpecifiedTargetArch=__TargetArchX64 + __TargetArchX86 + __TargetArchArm64
set /A __TotalSpecifiedTargetArch=__TargetArchX64 + __TargetArchX86 + __TargetArchArm + __TargetArchArm64
if %__TotalSpecifiedTargetArch% GTR 1 (
echo Error: more than one build architecture specified, but "all" not specified.
goto Usage
Expand All @@ -173,6 +176,7 @@ if "%__ProcessorArch%"=="" set __ProcessorArch=%PROCESSOR_ARCHITECTURE%

if %__TargetArchX64%==1 set __TargetArch=x64
if %__TargetArchX86%==1 set __TargetArch=x86
if %__TargetArchArm%==1 set __TargetArch=arm
if %__TargetArchArm64%==1 set __TargetArch=arm64
if "%__HostArch%" == "" set __HostArch=%__TargetArch%

Expand All @@ -187,6 +191,10 @@ if %__BuildTypeChecked%==1 set __BuildType=Checked
if %__BuildTypeRelease%==1 set __BuildType=Release

if %__EnforcePgo%==1 (
if %__TargetArchArm%==1 (
echo NOTICE: enforcepgo does nothing on arm architecture
set __EnforcePgo=0
)
if %__TargetArchArm64%==1 (
echo NOTICE: enforcepgo does nothing on arm64 architecture
set __EnforcePgo=0
Expand Down Expand Up @@ -443,7 +451,7 @@ REM ============================================================================

set __TargetArchList=

set /A __TotalSpecifiedTargetArch=__TargetArchX64 + __TargetArchX86 + __TargetArchArm64
set /A __TotalSpecifiedTargetArch=__TargetArchX64 + __TargetArchX86 + __TargetArchArm + __TargetArchArm64
if %__TotalSpecifiedTargetArch% EQU 0 (
REM Nothing specified means we want to build all architectures.
set __TargetArchList=x64 x86 arm arm64
Expand All @@ -453,6 +461,7 @@ REM Otherwise, add all the specified architectures to the list.

if %__TargetArchX64%==1 set __TargetArchList=%__TargetArchList% x64
if %__TargetArchX86%==1 set __TargetArchList=%__TargetArchList% x86
if %__TargetArchArm%==1 set __TargetArchList=%__TargetArchList% arm
if %__TargetArchArm64%==1 set __TargetArchList=%__TargetArchList% arm64

set __BuildTypeList=
Expand Down Expand Up @@ -536,7 +545,7 @@ echo All arguments are optional. The options are:
echo.
echo.-? -h -help --help: view this message.
echo -all: Builds all configurations and platforms.
echo Build architecture: one of -x64, -x86, -arm64 ^(default: -x64^).
echo Build architecture: one of -x64, -x86, -arm, -arm64 ^(default: -x64^).
echo Build type: one of -Debug, -Checked, -Release ^(default: -Debug^).
echo -component ^<name^> : specify this option one or more times to limit components built to those specified.
echo Allowed ^<name^>: hosts jit alljits runtime paltests iltools nativeaot spmi
Expand Down