Skip to content

Commit

Permalink
Merge pull request #105 from analogdevicesinc/tfcollins/synth-cron
Browse files Browse the repository at this point in the history
Add Jenkinsfile for Synthesis only to be used on scheduled basis
  • Loading branch information
tfcollins authored Mar 14, 2022
2 parents 023add8 + cdd4847 commit 7cc1016
Showing 1 changed file with 56 additions and 0 deletions.
56 changes: 56 additions & 0 deletions JenkinsfileCron
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
@Library('tfc-lib') _

dockerConfig = getDockerConfig(['MATLAB','Vivado'], matlabHSPro=false)
dockerConfig.add("-e MLRELEASE=R2021b")
dockerHost = 'docker'

////////////////////////////

hdlBranches = ['master','hdl_2019_r2']

stage("Build Toolbox") {
dockerParallelBuild(hdlBranches, dockerHost, dockerConfig) {
branchName ->
try {
withEnv(['HDLBRANCH='+branchName,'LC_ALL=C.UTF-8','LANG=C.UTF-8']) {
checkout scm
sh 'git submodule update --init'
sh 'make -C ./CI/scripts build'
sh 'pip3 install -r requirements_doc.txt'
sh 'make -C ./CI/gen_doc doc_ml'
sh 'make -C ./CI/scripts add_libad9361'
sh 'make -C ./CI/scripts gen_tlbx'
}
} catch(Exception ex) {
if (branchName == 'hdl_2019_r2') {
error('Production Toolbox Build Failed')
}
else {
unstable('Development Build Failed')
}
}
if (branchName == 'hdl_2019_r2') {
stash includes: '**', name: 'builtSources', useDefaultExcludes: false
archiveArtifacts artifacts: 'hdl/*', followSymlinks: false, allowEmptyArchive: true
}
}
}

/////////////////////////////////////////////////////

boardNames = ['zed','zc702','zc706','zcu102','adrv9361','adrv9364','pluto']
dockerConfig.add("-e HDLBRANCH=hdl_2019_r2")

stage("HDL Tests") {
dockerParallelBuild(boardNames, dockerHost, dockerConfig) {
branchName ->
withEnv(['BOARD='+branchName]) {
stage("Synth") {
unstash "builtSources"
sh 'make -C ./CI/scripts test_synth'
junit testResults: 'test/*.xml', allowEmptyResults: true
archiveArtifacts artifacts: 'test/logs/*', followSymlinks: false, allowEmptyArchive: true
}
}
}
}

0 comments on commit 7cc1016

Please sign in to comment.