Define the buildTarget function outside of the Jenkins pipeline
This commit is contained in:
parent
28fcc49572
commit
42ae8e1342
|
@ -1,13 +1,13 @@
|
|||
def buildTarget(String path, String rpmArch, String debArch) {
|
||||
cmakeBuild buildDir: 'cmake-build-${debArch}', buildType: 'release', cleanBuild: true, installation: 'Main'
|
||||
cmake arguments: '--build ./cmake-build-${debArch} --target ybcon', installation: 'Main',
|
||||
cmakeArgs: '-DCMAKE_C_COMPILER=/usr/bin/${path}-gcc -DCMAKE_CXX_COMPILER=/usr/bin/${path}-g++ -DCMAKE_LINKER=/usr/bin/${path}-ld.gold -DCMAKE_AR=/usr/bin/${path}-ar -DCPACK_RPM_PACKAGE_ARCHITECTURE=${rpmArch} -DCPACK_DEBIAN_PACKAGE_ARCHITECTURE=${debArch}'
|
||||
cpack installation: 'Main', workingDir: 'cmake-build-{debArch}'
|
||||
}
|
||||
|
||||
pipeline { // Multi-branch pipeline script for Yerbacon.
|
||||
agent any
|
||||
|
||||
def buildTarget(String path, String rpmArch, String debArch) {
|
||||
cmakeBuild buildDir: 'cmake-build-${debArch}', buildType: 'release', cleanBuild: true, installation: 'Main'
|
||||
cmake arguments: '--build ./cmake-build-${debArch} --target ybcon', installation: 'Main',
|
||||
cmakeArgs: '-DCMAKE_C_COMPILER=/usr/bin/${path}-gcc -DCMAKE_CXX_COMPILER=/usr/bin/${path}-g++ -DCMAKE_LINKER=/usr/bin/${path}-ld.gold -DCMAKE_AR=/usr/bin/${path}-ar -DCPACK_RPM_PACKAGE_ARCHITECTURE=${rpmArch} -DCPACK_DEBIAN_PACKAGE_ARCHITECTURE=${debArch}'
|
||||
cpack installation: 'Main', workingDir: 'cmake-build-{debArch}'
|
||||
}
|
||||
|
||||
options {
|
||||
buildDiscarder(logRotator(numToKeepStr: '48', artifactNumToKeepStr: '96'))
|
||||
timeout(time: 8, unit: 'MINUTES')
|
||||
|
|
Loading…
Reference in New Issue