Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit ec49c39

Browse files
sdmacleammitche
authored andcommitted
[Arm64] Switch to new pipelines.groovy CI (#28280)
* [Arm64] Stop running Ubuntu16.04 arm64 Debug Build on PR * [Arm64] Switch to new pipelines.groovy CI
1 parent 3c5ecc1 commit ec49c39

File tree

4 files changed

+52
-125
lines changed

4 files changed

+52
-125
lines changed

buildpipeline/linux.arm64.groovy

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
@Library('dotnet-ci') _
2+
3+
// Incoming parameters. Access with "params.<param name>".
4+
// Note that the parameters will be set as env variables so we cannot use names that conflict
5+
// with the engineering system parameter names.
6+
// CGroup - Build configuration.
7+
// TestOuter - If true, runs outerloop, if false runs just innerloop
8+
9+
def submittedHelixJson = null
10+
11+
simpleDockerNode('microsoft/dotnet-buildtools-prereqs:ubuntu-16.04-cross-arm64-a3ae44b-20180315221921') {
12+
stage ('Checkout source') {
13+
checkoutRepo()
14+
}
15+
16+
def logFolder = getLogFolder()
17+
18+
stage ('Initialize tools') {
19+
// Init tools
20+
sh './init-tools.sh'
21+
}
22+
stage ('Generate version assets') {
23+
// Generate the version assets. Do we need to even do this for non-official builds?
24+
sh "./build-managed.sh -- /t:GenerateVersionSourceFile /p:GenerateVersionSourceFile=true"
25+
}
26+
stage ('Sync') {
27+
sh "./sync.sh -p -BuildTests=false -- /p:ArchGroup=arm64"
28+
}
29+
// For arm64 cross builds we split the 'Build Product' build.sh command into 3 separate parts
30+
stage ('Build Native') {
31+
sh """
32+
export ROOTFS_DIR=/crossrootfs/arm64
33+
./build-native.sh -buildArch=arm64 -${params.CGroup}
34+
"""
35+
}
36+
stage ('Build Managed') {
37+
// Cross build builds Linux Managed components using x64 target
38+
// We do not want x64 packages
39+
sh "./build-managed.sh -BuildPackages=false -buildArch=x64 -${params.CGroup}"
40+
}
41+
stage ('Build Packages') {
42+
sh "./build-packages.sh -buildArch=arm64 -${params.CGroup}"
43+
}
44+
45+
// TODO: Build Tests for arm64 when possible
46+
47+
// TODO: Add submission for Helix testing once we have queue for arm64 Linux working
48+
}
49+
50+
// TODO: Add "Execute tests" stage once we have queue for arm64 Linux working

buildpipeline/pipelinejobs.groovy

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,15 @@ def branch = GithubBranchName
1515
// **************************
1616

1717
def linPipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/linux.groovy')
18+
def linArm64Pipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/linux.arm64.groovy')
1819
def centos6Pipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/centos.6.groovy')
1920
def alpine36Pipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/alpine.3.6.groovy')
2021
def osxPipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/osx.groovy')
2122
def winPipeline = Pipeline.createPipelineForGithub(this, project, branch, 'buildpipeline/windows.groovy')
2223

2324
def configurations = [
2425
['TGroup':"netcoreapp", 'Pipeline':linPipeline, 'Name':'Linux' ,'ForPR':"Release-x64", 'Arch':['x64']],
26+
['TGroup':"netcoreapp", 'Pipeline':linArm64Pipeline, 'Name':'Linux' ,'ForPR':"Release-arm64", 'Arch':['arm64']],
2527
['TGroup':"netcoreapp", 'Pipeline':centos6Pipeline, 'Name':'CentOS.6' ,'ForPR':"", 'Arch':['x64']],
2628
['TGroup':"netcoreapp", 'Pipeline':alpine36Pipeline, 'Name':'Alpine.3.6' ,'ForPR':"Debug-x64", 'Arch':['x64']],
2729
['TGroup':"netcoreapp", 'Pipeline':osxPipeline, 'Name':'OSX', 'ForPR':"Debug-x64", 'Arch':['x64']],

cross/arm64_ci_script.sh

Lines changed: 0 additions & 63 deletions
This file was deleted.

netci.groovy

Lines changed: 0 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -345,68 +345,6 @@ def targetGroupOsMapInnerloop = ['netcoreapp': ['Windows_NT', 'Ubuntu14.04', 'Ub
345345
} // targetGroup
346346
} // isPR
347347

348-
// **************************
349-
// Define Linux ARM64 cross builds. These jobs run on every merge.
350-
// Some jobs run on every PR. The ones that don't run per PR can be requested via a phrase.
351-
// **************************
352-
[true, false].each { isPR ->
353-
['netcoreapp'].each { targetGroup ->
354-
['Debug', 'Release'].each { configurationGroup ->
355-
def osGroup = "Linux"
356-
def archGroup = 'arm64'
357-
def osName = 'Ubuntu16.04'
358-
359-
def newJobName = "${osName.toLowerCase()}_arm64_cross_${configurationGroup.toLowerCase()}"
360-
361-
def newJob = job(Utilities.getFullJobName(project, newJobName, isPR)) {
362-
steps {
363-
// Call the arm64_ci_script.sh script to perform the cross build of native corefx
364-
def script = "./cross/arm64_ci_script.sh --buildConfig=${configurationGroup.toLowerCase()}"
365-
shell(script)
366-
367-
// Tar up the appropriate bits.
368-
shell("tar -czf bin/build.tar.gz --directory=\"bin/Linux.${archGroup}.${configurationGroup}/native\" .")
369-
}
370-
}
371-
372-
// The cross build jobs run on Ubuntu. The arm-cross-latest version
373-
// contains the packages needed for cross building corefx
374-
Utilities.setMachineAffinity(newJob, 'Ubuntu14.04', 'arm-cross-latest')
375-
376-
// Set up standard options.
377-
Utilities.standardJobSetup(newJob, project, isPR, "*/${branch}")
378-
379-
// Add archival for the built binaries
380-
def archiveContents = "bin/build.tar.gz"
381-
Utilities.addArchival(newJob, archiveContents)
382-
383-
newJob.with {
384-
publishers {
385-
azureVMAgentPostBuildAction {
386-
agentPostBuildAction('Delete agent after build execution (when idle).')
387-
}
388-
}
389-
}
390-
391-
// Set up triggers
392-
if (isPR) {
393-
if (configurationGroup == "Release") {
394-
// Run Arm64 Linux Release job automatically for PR builds
395-
Utilities.addGithubPRTriggerForBranch(newJob, branch, "${osName} arm64 ${configurationGroup} Build")
396-
}
397-
else {
398-
// Add Arm64 Linux Debug job hook
399-
Utilities.addGithubPRTriggerForBranch(newJob, branch, "${osName} arm64 ${configurationGroup} Build", "(?i).*test\\W+${osName}\\W+arm64\\W+${configurationGroup}.*")
400-
}
401-
}
402-
else {
403-
// Set a push trigger
404-
Utilities.addGithubPushTrigger(newJob)
405-
}
406-
} // configurationGroup
407-
} // targetGroup
408-
} // isPR
409-
410348
// **************************
411349
// Define Linux x86 builds. These jobs run daily and results will be used for CoreCLR test
412350
// TODO: innerloop & outerloop testing & merge to general job generation routine

0 commit comments

Comments
 (0)