Changeset 255b294 for Jenkins/FullBuild
- Timestamp:
- Feb 24, 2017, 1:28:00 PM (7 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 23c4aa8
- Parents:
- c00ddfe (diff), 783dfd6 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Jenkins/FullBuild
rc00ddfe r255b294 1 1 #!groovy 2 2 3 //=========================================================================================================== 4 // Main loop of the compilation 5 //=========================================================================================================== 6 7 node ('master') { 8 def err = null 9 10 try { 11 //Prevent the build from exceeding 30 minutes 12 timeout(60) { 13 14 //Wrap build to add timestamp to command line 15 wrap([$class: 'TimestamperBuildWrapper']) { 16 17 stage 'Build' 18 19 results = [null, null] 20 21 parallel ( 22 gcc_6_x64: { trigger_build( 'gcc-6', 'x64' ) }, 23 gcc_6_x86: { trigger_build( 'gcc-6', 'x86' ) }, 24 gcc_5_x64: { trigger_build( 'gcc-5', 'x64' ) }, 25 gcc_5_x86: { trigger_build( 'gcc-5', 'x86' ) }, 26 gcc_4_x64: { trigger_build( 'gcc-4.9', 'x64' ) }, 27 gcc_4_x86: { trigger_build( 'gcc-4.9', 'x86' ) }, 28 clang_x64: { trigger_build( 'clang', 'x64' ) }, 29 clang_x86: { trigger_build( 'clang', 'x86' ) }, 30 ) 31 32 //Push latest changes to do-lang repo 33 push_build() 34 } 35 } 36 } 37 38 //If an exception is caught we need to change the status and remember to 39 //attach the build log to the email 40 catch (Exception caughtError) { 41 echo('error caught') 42 43 //rethrow error later 44 err = caughtError 45 46 //Store the result of the build log 47 currentBuild.result = 'FAILURE' 48 49 //Send email to notify the failure 50 promote_failure_email() 51 } 52 53 finally { 54 //Must re-throw exception to propagate error 55 if (err) { 56 throw err 57 } 58 } 59 } 3 60 //=========================================================================================================== 4 61 // Main compilation routines 5 62 //=========================================================================================================== 6 63 7 def trigger_build(String arch) {64 def trigger_build(String cc, String arch) { 8 65 def result = build job: 'Cforall/master', \ 9 66 parameters: [ \ 67 [$class: 'StringParameterValue', \ 68 name: 'pCompiler', \ 69 value: cc], \ 70 [$class: 'StringParameterValue', \ 71 name: 'pArchitecture', \ 72 value: arch], \ 10 73 [$class: 'BooleanParameterValue', \ 11 name: ' isFullBuild',\74 name: 'pRunAllTests', \ 12 75 value: true], \ 13 [$class: 'StringParameterValue', \ 14 name: 'buildArchitecture', \ 15 value: arch] \ 76 [$class: 'BooleanParameterValue', \ 77 name: 'pRunBenchmark', \ 78 value: true], \ 79 [$class: 'BooleanParameterValue', \ 80 name: 'pBuildDocumentation', \ 81 value: true], \ 82 [$class: 'BooleanParameterValue', \ 83 name: 'pPublish', \ 84 value: true], \ 85 [$class: 'BooleanParameterValue', \ 86 name: 'pSilent', \ 87 value: true], \ 16 88 ], \ 17 89 propagate: false … … 69 141 70 142 //=========================================================================================================== 71 // Main loop of the compilation72 //===========================================================================================================73 74 node ('master') {75 def err = null76 77 try {78 //Prevent the build from exceeding 30 minutes79 timeout(60) {80 81 //Wrap build to add timestamp to command line82 wrap([$class: 'TimestamperBuildWrapper']) {83 84 stage 'Build'85 86 results = [null, null]87 88 parallel (89 x64: {90 trigger_build('64-bit')91 },92 x32: {93 trigger_build('32-bit')94 }95 )96 97 //Push latest changes to do-lang repo98 push_build()99 }100 }101 }102 103 //If an exception is caught we need to change the status and remember to104 //attach the build log to the email105 catch (Exception caughtError) {106 echo('error caught')107 108 //rethrow error later109 err = caughtError110 111 //Store the result of the build log112 currentBuild.result = 'FAILURE'113 114 //Send email to notify the failure115 promote_failure_email()116 }117 118 finally {119 //Must re-throw exception to propagate error120 if (err) {121 throw err122 }123 }124 }125 //===========================================================================================================126 143 //Routine responsible of sending the email notification once the build is completed 127 144 //===========================================================================================================
Note: See TracChangeset
for help on using the changeset viewer.