forked from log4cplus/log4cplus
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Jenkinsfile
71 lines (67 loc) · 3.02 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
pipeline {
agent none
stages {
stage ('properties'){
agent { label 'master' }
steps {
script {
properties([buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '', daysToKeepStr: '', numToKeepStr: '10')), [$class: 'ScannerJobProperty', doNotScan: false], gitLabConnection('CERN GitLlab'), [$class: 'CopyArtifactPermissionProperty', projectNames: '*']])
}
}
}
stage ('Checkout'){
parallel {
stage('Windows') {
agent { label "windows" }
steps {
deleteDir()
checkout([$class: 'GitSCM', branches: [[name: 'master']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'SubmoduleOption', disableSubmodules: false, parentCredentials: false, recursiveSubmodules: true, reference: '', trackingSubmodules: false]], submoduleCfg: [], userRemoteConfigs: [[url: 'https://github.com/CERN/log4cplus']]])
}
}
stage('Unix') {
agent { label "unix" }
steps {
deleteDir()
checkout([$class: 'GitSCM', branches: [[name: 'master']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'SubmoduleOption', disableSubmodules: false, parentCredentials: false, recursiveSubmodules: true, reference: '', trackingSubmodules: false]], submoduleCfg: [], userRemoteConfigs: [[url: 'https://github.com/CERN/log4cplus']]])
}
}
}
}
stage('Build') {
parallel {
stage('Windows') {
agent { label "windows" }
steps {
script {
def msbuild = tool name: '14.0', type: 'msbuild'
bat "\"${msbuild}\" msvc14/log4cplus.vcxproj /p:Configuration=Release /p:Platform=\"x64\" "
}
}
}
stage('Unix') {
agent { label "unix" }
steps {
sh './configure --enable-so-version=no && autoreconf -f -i && make'
}
}
}
}
stage ('Archive'){
parallel {
stage('Windows') {
agent { label "windows" }
steps {
archiveArtifacts artifacts:'msvc14/x64/bin.Release/*.*',fingerprint:true
}
}
stage('Unix') {
agent { label "unix" }
steps {
archiveArtifacts artifacts:'.libs/liblog4cplus-2.0.so',fingerprint:true
archiveArtifacts artifacts:'include/log4cplus/**/*.*',fingerprint:true
}
}
}
}
}
}