Compare commits

...
Author SHA1 Message Date
John Colvin 6a2ca8045e fix build (jenkins): Check if 'targets' is None 2023-07-17 10:34:23 -04:00
John Colvin be6a252039 build: Default to Release for 'publish' target
The jenkins build script (jenkins_build_spark.cmd) specifies
'--target publish' but not '--configuration Release'. It was building
debug by default (not what we want). This fixes that as a side effect.
2023-07-17 00:10:27 -04:00
John Colvin 2456c1a3a4 build: Add build-script for jenkins 2023-07-16 23:50:06 -04:00
John Colvin 84e61123a1 turn echo on for build_spark.cmd (troubleshoot jenkins) 2023-07-16 17:14:02 -04:00
John Colvin f9f2379d3e fix spark.Jenkinsfile 2023-07-16 15:14:29 -04:00
John Colvin 02f6f3475c Add 'call' to bat steps in jenkinsfile 2023-07-16 15:12:07 -04:00
John Colvin 775dba6377 troubleshoot Jenkins - restore orig pipeline steps 2023-07-16 14:39:08 -04:00
John Colvin adb190a0e0 troubleshoot Jenkins 2 2023-07-16 14:29:28 -04:00
John Colvin b1c7d1300d troubleshoot Jenkins Pipeline 2023-07-16 14:23:24 -04:00
John Colvin ee925a12f9 tweak spark.Jenkinsfile 2023-07-16 12:02:01 -04:00
John Colvin 621a4b2ca7 nothing 2023-07-16 11:53:55 -04:00
John Colvin 250a258935 build: Add Jenkinsfile for spark (client) 2023-07-16 11:46:56 -04:00
John Colvin 95d97a69da build: Add Jenkinsfile for sparkd 2023-07-09 17:02:31 -04:00
John Colvin dfce23a33d test 2 2023-07-07 18:03:34 -04:00
John Colvin 709334a1aa test 2023-07-07 17:47:07 -04:00
5 changed files with 112 additions and 5 deletions

No files matched your search

+61
View File
@@ -0,0 +1,61 @@
pipeline {
agent {
label 'os=windows && ram=8gb && installed=vs2022 && installed=python3'
}
stages {
stage('Build') {
steps {
echo 'Building..'
script {
if (fileExists('.venv')) {
echo 'Using existing Python virtual env'
} else {
echo 'Creating Python virtual env'
bat 'tools\\ensure_venv.cmd'
}
}
bat """
call .venv\\Scripts\\activate
call pip install -r requirements.txt
call python tools\\py\\build_spark.py --configuration Release
"""
}
post {
always {
echo '========Build Done========'
}
success {
echo '========Build executed successfully========'
}
failure {
echo '========Build execution failed========'
}
}
}
stage('Installing') {
steps {
echo 'Installing...'
bat """
"C:\\Program Files\\7-Zip\7z.exe" a -tzip Release.zip "build\\Release"
"""
}
}
stage('Archiving') {
steps {
echo 'Archiving...'
archiveArtifacts artifacts: 'Release.zip', followSymlinks: false, onlyIfSuccessful: true
}
}
}
post {
always {
echo '========Pipeline Done========'
}
success {
echo '========Pipeline executed successfully ========'
}
failure {
echo '========Pipeline execution failed========'
}
}
}
+38
View File
@@ -0,0 +1,38 @@
pipeline {
agent {
label 'lab-main'
}
stages {
stage('Build') {
steps {
echo 'Building..'
if (!fileExists('.venv')) {
echo 'Creating python virtual env'
sh 'python3 -m venv .venv'
}
sh """
. .venv/bin/activate
pip install -r requirements.txt
python tools/py/build_sparkd.py --compiler gcc --configuration release
"""
}
}
stage('Installing') {
steps {
echo 'Installing..'
sh """
cd build/gcc/release
cmake --build . --target install
"""
sh 'tar -czf install.tar.gz install'
}
}
stage('Archiving') {
steps {
echo 'Archiving..'
archiveArtifacts artifacts: 'install.tar.gz', followSymlinks: false, onlyIfSuccessful: true
}
}
}
}
+1 -1
View File
@@ -1,4 +1,4 @@
@echo off
@echo on
@call %~dp0..\tools\ensure_venv.cmd
touch %~dp0..\src\lib\CMakeLists.txt
+8
View File
@@ -0,0 +1,8 @@
@echo off
call "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\Common7\\Tools\\VsDevCmd.bat"
call .venv\\Scripts\\activate
call set PYTHONPATH=%~dp0\..\.venv\Scripts\python
call .venv\Scripts\python.exe tools\py\build_spark.py %*
EXIT /B %ERRORLEVEL%
+4 -4
View File
@@ -173,8 +173,7 @@ def _get_arg_parser():
metavar='debug|release',
type=str,
nargs='?',
help='The build configuration',
default='Debug')
help='The build configuration')
parser.add_argument(
'-o',
@@ -336,9 +335,10 @@ def _main():
link_build_dir = arg_to_path(get_arg(args_dict, 'link_output_dir'))
targets = flatten_arglist(get_arg(args_dict, 'target'))
verbosity = get_arg(args_dict, 'verbosity') or None
configuration = args.configuration or 'Release' if targets is not None and any(
filter(lambda t: t.lower() == 'publish', targets)) else 'Debug'
build(
configuration=args.configuration,
configuration=configuration,
clean=args.clean,
restore=args.restore,
build_dir=build_dir,