All checks were successful
JCS-Prod/RSE-Texture/pipeline/head This commit looks good
67 lines
2.9 KiB
Groovy
67 lines
2.9 KiB
Groovy
pipeline {
|
|
agent any
|
|
options {
|
|
skipDefaultCheckout(true)
|
|
}
|
|
environment {
|
|
CI_OUTPUT_NAME = "RSE_Texture"
|
|
CI_BUILD_NUMBER = "$BUILD_NUMBER"
|
|
}
|
|
stages {
|
|
stage('Prepare') {
|
|
steps {
|
|
cleanWs()
|
|
}
|
|
}
|
|
stage('Build') {
|
|
steps {
|
|
parallel(
|
|
linux: {
|
|
dir("linux") {
|
|
checkout([$class: 'GitSCM', branches: [[name: '**']], browser: [$class: 'GiteaBrowser', repoUrl: 'https://git.jcsmith.fr/JCS-Prod/RSE-Texture'], extensions: [], userRemoteConfigs: [[credentialsId: 'jenkins-ssh', url: 'ssh://git@git.jcsmith.fr:2322/JCS-Prod/RSE-Texture.git']]])
|
|
cmakeBuild buildDir: 'build', installation: 'latest', steps: [[args: 'all']]
|
|
}
|
|
},
|
|
windows: {
|
|
dir("windows") {
|
|
checkout([$class: 'GitSCM', branches: [[name: '**']], browser: [$class: 'GiteaBrowser', repoUrl: 'https://git.jcsmith.fr/JCS-Prod/RSE-Texture'], extensions: [], userRemoteConfigs: [[credentialsId: 'jenkins-ssh', url: 'ssh://git@git.jcsmith.fr:2322/JCS-Prod/RSE-Texture.git']]])
|
|
cmakeBuild buildDir: 'build', cmakeArgs: '-DGNU_HOST=x86_64-w64-mingw32 -DCMAKE_TOOLCHAIN_FILE=../mingw_cross_toolchain.cmake -D"ZLIB_INCLUDE_DIR=/mnt/cc-libs/mingw64/zlib/1.2.11/include" -D"ZLIB_LIBRARY=/mnt/cc-libs/mingw64/zlib/1.2.11/lib/libzlib.dll.a" -D"PNG_PNG_INCLUDE_DIR=/mnt/cc-libs/mingw64/libpng/1.6.37/include" -D"PNG_LIBRARY=/mnt/cc-libs/mingw64/libpng/1.6.37/lib/libpng.dll.a"', installation: 'latest', steps: [[args: 'all']]
|
|
}
|
|
}
|
|
)
|
|
}
|
|
}
|
|
stage('Deploy') {
|
|
steps {
|
|
dir("zip_linux") {
|
|
sh 'cp ../linux/build/${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}* .'
|
|
}
|
|
dir("zip_win") {
|
|
sh 'cp ../windows/build/${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}* /mnt/cc-libs/mingw64/zlib/1.2.11/bin/libzlib.dll /mnt/cc-libs/mingw64/libpng/1.6.37/bin/libpng16.dll .'
|
|
}
|
|
zip archive: false, dir: 'zip_linux', exclude: '', glob: '', zipFile: 'x64.zip'
|
|
sh 'mv x64.zip ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_x64.zip'
|
|
zip archive: false, dir: 'zip_win', exclude: '', glob: '', zipFile: 'mingw64.zip'
|
|
sh 'mv mingw64.zip ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_mingw64.zip'
|
|
}
|
|
}
|
|
stage('Sign') {
|
|
steps {
|
|
sh 'ls -l'
|
|
sh 'gpg --batch --detach-sign -o ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_x64.zip.gpg ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_x64.zip'
|
|
sh 'gpg --batch --detach-sign -o ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_mingw64.zip.gpg ${CI_OUTPUT_NAME}-1.0.1.${BUILD_NUMBER}_mingw64.zip'
|
|
archiveArtifacts(artifacts: '*.zip,*.gpg')
|
|
}
|
|
}
|
|
}
|
|
/*
|
|
post {
|
|
always {
|
|
cleanWs(cleanWhenNotBuilt: false,
|
|
deleteDirs: true,
|
|
disableDeferredWipeout: true,
|
|
notFailBuild: true)
|
|
}
|
|
}
|
|
*/
|
|
} |