diff --git a/JenkinsfileCron b/JenkinsfileCron new file mode 100644 index 00000000..49e694cc --- /dev/null +++ b/JenkinsfileCron @@ -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 + } + } + } +} \ No newline at end of file