Merge pull request 'Adding .deb builds' (#9) from main into release
Reviewed-on: https://codeberg.org/retropikzel/compile-scheme/pulls/9
This commit is contained in:
commit
813d7caf76
|
|
@ -1,5 +1,6 @@
|
||||||
FROM debian:trixie-slim
|
FROM debian:trixie
|
||||||
RUN apt-get update && apt-get install -y gcc make git libffi-dev docker.io
|
RUN apt-get update && apt-get install -y \
|
||||||
|
gcc make git libffi-dev docker.io
|
||||||
WORKDIR /cache
|
WORKDIR /cache
|
||||||
RUN git clone https://github.com/ashinn/chibi-scheme.git --depth=1
|
RUN git clone https://github.com/ashinn/chibi-scheme.git --depth=1
|
||||||
WORKDIR /cache/chibi-scheme
|
WORKDIR /cache/chibi-scheme
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,14 @@ pipeline {
|
||||||
agent {
|
agent {
|
||||||
dockerfile {
|
dockerfile {
|
||||||
label 'docker-x86_64'
|
label 'docker-x86_64'
|
||||||
filename 'Dockerfile.jenkins'
|
filename 'Dockerfile.jenkins'
|
||||||
args '--user=root --privileged -v /var/run/docker.sock:/var/run/docker.sock'
|
args '--user=root --privileged -v /var/run/docker.sock:/var/run/docker.sock'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
options {
|
options {
|
||||||
disableConcurrentBuilds()
|
disableConcurrentBuilds()
|
||||||
buildDiscarder(logRotator(numToKeepStr: '10', artifactNumToKeepStr: '10'))
|
buildDiscarder(logRotator(numToKeepStr: '10', artifactNumToKeepStr: '10'))
|
||||||
}
|
}
|
||||||
|
|
||||||
parameters {
|
parameters {
|
||||||
|
|
@ -20,37 +20,36 @@ pipeline {
|
||||||
|
|
||||||
stages {
|
stages {
|
||||||
stage('Build and install') {
|
stage('Build and install') {
|
||||||
|
when { not { branch 'release' } }
|
||||||
steps {
|
steps {
|
||||||
sh "make build-chibi"
|
sh "make build-chibi"
|
||||||
sh "make install"
|
sh "make install"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Test') {
|
stage('R6RS') {
|
||||||
parallel {
|
when { not { branch 'release' } }
|
||||||
stage('R6RS') {
|
steps {
|
||||||
steps {
|
script {
|
||||||
script {
|
R6RS_SCHEMES.split().each { SCHEME ->
|
||||||
R7RS_SCHEMES.split().each { SCHEME ->
|
stage("${SCHEME} R6RS") {
|
||||||
stage("${SCHEME} R6RS") {
|
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
||||||
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
sh "make SCHEME=${SCHEME} test-r6rs-docker"
|
||||||
sh "make SCHEME=${SCHEME} test-r6rs-docker"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
stage('R7RS') {
|
stage('R7RS') {
|
||||||
steps {
|
when { not { branch 'release' } }
|
||||||
script {
|
steps {
|
||||||
R7RS_SCHEMES.split().each { SCHEME ->
|
script {
|
||||||
stage("${SCHEME} R7RS") {
|
R7RS_SCHEMES.split().each { SCHEME ->
|
||||||
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
stage("${SCHEME} R7RS") {
|
||||||
sh "make SCHEME=${SCHEME} test-r7rs-docker"
|
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
||||||
}
|
sh "make SCHEME=${SCHEME} test-r7rs-docker"
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -61,7 +60,7 @@ pipeline {
|
||||||
stage('.deb package') {
|
stage('.deb package') {
|
||||||
steps {
|
steps {
|
||||||
sh "make deb"
|
sh "make deb"
|
||||||
archiveArtifacts artifacts: '*.deb', allowEmptyArchive: true, fingerprint: true, onlyIfSuccessful: true
|
archiveArtifacts artifacts: '*.deb', allowEmptyArchive: true, fingerprint: true, onlyIfSuccessful: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
2
Makefile
2
Makefile
|
|
@ -102,7 +102,6 @@ test-r6rs:
|
||||||
mkdir -p ${R6RSTMP}
|
mkdir -p ${R6RSTMP}
|
||||||
cp -r r6rs-testfiles/* ${R6RSTMP}/
|
cp -r r6rs-testfiles/* ${R6RSTMP}/
|
||||||
cd ${R6RSTMP} && COMPILE_R7RS=${SCHEME} compile-scheme -I ./libs -o main --debug main.sps
|
cd ${R6RSTMP} && COMPILE_R7RS=${SCHEME} compile-scheme -I ./libs -o main --debug main.sps
|
||||||
cd ${R6RSTMP} && file main
|
|
||||||
cd ${R6RSTMP} && ./main 1 2 3 > test-result.txt
|
cd ${R6RSTMP} && ./main 1 2 3 > test-result.txt
|
||||||
@grep "Test successfull (\"1\" \"2\" \"3\")" ${R6RSTMP}/test-result.txt || (echo "Test failed, output: " && cat ${R6RSTMP}/test-result.txt && exit 1)
|
@grep "Test successfull (\"1\" \"2\" \"3\")" ${R6RSTMP}/test-result.txt || (echo "Test failed, output: " && cat ${R6RSTMP}/test-result.txt && exit 1)
|
||||||
|
|
||||||
|
|
@ -115,7 +114,6 @@ test-r7rs:
|
||||||
mkdir -p ${R7RSTMP}
|
mkdir -p ${R7RSTMP}
|
||||||
cp -r r7rs-testfiles/* ${R7RSTMP}/
|
cp -r r7rs-testfiles/* ${R7RSTMP}/
|
||||||
cd ${R7RSTMP} && COMPILE_R7RS=${SCHEME} compile-scheme -I ./libs -o main --debug main.scm
|
cd ${R7RSTMP} && COMPILE_R7RS=${SCHEME} compile-scheme -I ./libs -o main --debug main.scm
|
||||||
cd ${R7RSTMP} && file main
|
|
||||||
-cd ${R7RSTMP} && ./main 1 2 3 > test-result.txt 2>&1
|
-cd ${R7RSTMP} && ./main 1 2 3 > test-result.txt 2>&1
|
||||||
@grep "Test successfull (\"1\" \"2\" \"3\")" ${R7RSTMP}/test-result.txt || (echo "Test failed, output: " && cat ${R7RSTMP}/test-result.txt && exit 1)
|
@grep "Test successfull (\"1\" \"2\" \"3\")" ${R7RSTMP}/test-result.txt || (echo "Test failed, output: " && cat ${R7RSTMP}/test-result.txt && exit 1)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue