38 lines
1.0 KiB
Groovy
38 lines
1.0 KiB
Groovy
pipeline {
|
|
agent none
|
|
|
|
stages {
|
|
stage('Build Linux') {
|
|
agent { label 'linux' }
|
|
steps {
|
|
cleanWs()
|
|
checkout scm
|
|
|
|
sh '''
|
|
cmake -S . -B build/linux -G Ninja -DCMAKE_BUILD_TYPE=Release
|
|
cmake --build build/linux
|
|
archiveArtifacts artifacts: 'build/linux/test_app', fingerprint: true
|
|
'''
|
|
}
|
|
}
|
|
|
|
stage('Build Windows') {
|
|
agent { label 'windows' }
|
|
steps {
|
|
cleanWs()
|
|
checkout scm
|
|
|
|
bat '''
|
|
call "C:\\Program Files (x86)\\Microsoft Visual Studio\\2022\\BuildTools\\VC\\Auxiliary\\Build\\vcvars64.bat"
|
|
|
|
cmake -S . -B build\\windows -G Ninja ^
|
|
-DCMAKE_BUILD_TYPE=Release ^
|
|
-DCMAKE_TOOLCHAIN_FILE=C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake
|
|
|
|
cmake --build build\\windows
|
|
archiveArtifacts artifacts: 'build/windows/test_app.exe', fingerprint: true
|
|
'''
|
|
}
|
|
}
|
|
}
|
|
} |