summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Jenkinsfile48
-rw-r--r--Jenkinsfile.old117
-rwxr-xr-xbuildqt32.bat16
-rwxr-xr-xbuildqt64.bat15
4 files changed, 189 insertions, 7 deletions
diff --git a/Jenkinsfile b/Jenkinsfile
new file mode 100644
index 0000000..e846baf
--- /dev/null
+++ b/Jenkinsfile
@@ -0,0 +1,48 @@
+def REPO = 'ssh://gerrit1.techsat.local:29418/external/Qt'
+
+stage('Build') {
+ parallel linux: {
+ node('linux') {
+ deleteDir()
+ checkout([$class: 'GitSCM',
+ branches: [[name: 'features/newbuild']],
+ doGenerateSubmoduleConfigurations: false,
+ extensions: [],
+ submoduleCfg: [],
+ userRemoteConfigs: [[url: REPO]]])
+ sh '''#!/bin/bash
+ source /opt/centos/devtoolset-1.1/enable
+ gcc -v
+ make
+ '''
+ archiveArtifacts artifacts: 'qt-*-x86-linux64.zip'
+ }
+ },
+ windows: {
+ node('windows') {
+ deleteDir()
+ checkout([$class: 'GitSCM',
+ branches: [[name: 'features/newbuild']],
+ doGenerateSubmoduleConfigurations: false,
+ extensions: [],
+ submoduleCfg: [],
+ userRemoteConfigs: [[url: REPO]]])
+ bat '''@echo off
+ net use K: \\\\dfs2.techsat.net\\dev-tools /yes > NUL 2>&1
+ set SDKDIR=K:\\WinSDK\\VS2019BT\\
+ set PERLDIR=K:\\perl\\x86_64-msvc\\
+ buildqt32.bat
+ '''
+ bat '''@echo off
+ net use K: \\\\dfs2.techsat.net\\dev-tools /yes > NUL 2>&1
+ set SDKDIR=K:\\WinSDK\\VS2019BT\\
+ set PERLDIR=K:\\perl\\x86_64-msvc\\
+ buildqt64.bat
+ '''
+ bat '''@echo off
+ net use K: /delete /yes >NUL 2>&1
+ '''
+ archiveArtifacts artifacts: 'qt-*-msvc.zip'
+ }
+ }
+}
diff --git a/Jenkinsfile.old b/Jenkinsfile.old
new file mode 100644
index 0000000..e1dbc75
--- /dev/null
+++ b/Jenkinsfile.old
@@ -0,0 +1,117 @@
+def REPO = 'ssh://gerrit1.techsat.local:29418/external/Qt'
+
+node ('build6-win10-64') {
+ stage('Prepare environment') {
+ result = sh returnStatus: true, script: '''
+CWD=`pwd`
+export WORKSPACE=`cygpath $WORKSPACE`
+rm -Rf $WORKSPACE/*
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+
+ stage('Prepare environment') {
+ checkout([$class: 'GitSCM',
+ branches: [[name: 'master']],
+ doGenerateSubmoduleConfigurations: false,
+ extensions: [],
+ submoduleCfg: [],
+ userRemoteConfigs: [[url: REPO]]])
+
+ step ([$class: 'CopyArtifact',
+ projectName: '202151_NG_ADS2-Tools-GCC-Suite',
+ filter: 'gcc-suite-*-x86-mingw64.zip']);
+
+ result = sh returnStatus: true, script: '''
+echo $HOME
+pwd
+mkdir Qt-5.9.1
+unzip gcc-suite-*-x86-mingw64.zip
+rm -f gcc-suite-*-x86-mingw64.zip
+mv gcc-* gcc
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+
+ stage('unzip qt') {
+ result = sh returnStatus: true, script: '''
+TOP=`pwd`
+cd SOURCE
+/c/"Program Files"/7-Zip/7z.exe x qt-everywhere-opensource-src-*.zip -o.. -y -r
+cd ..
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+
+ stage('configure qt') {
+ result = sh returnStatus: true, script: '''
+TOP=`pwd`
+export WORKSPACE=`cygpath $WORKSPACE`
+P=`cygpath $DSB_PKGS/x86-mingw64/msys/usr/bin`
+export PATH=$WORKSPACE/gcc/bin:$P
+hash -r gcc
+hash -r g++
+gcc --version
+cp -f $WORKSPACE/SOURCE/win32-g++.nativ.qmake.conf $WORKSPACE/qt-everywhere-opensource-src-5.9.1/qtbase/mkspecs/win32-g++/qmake.conf
+cd $WORKSPACE/qt-everywhere-opensource-src-5.9.1
+./configure -prefix $WORKSPACE/Qt-5.9.1 -release -opensource -confirm-license -optimized-tools -strip -platform win32-g++ -opengl desktop -nomake tests
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+
+ stage('build qt') {
+ result = sh returnStatus: true, script: '''
+export WORKSPACE=`cygpath $WORKSPACE`
+cd $WORKSPACE
+TOP=`pwd`
+P=`cygpath $DSB_PKGS/x86-mingw64/msys/usr/bin`
+export PATH=$WORKSPACE/gcc-7.1.0/bin:$P
+hash -r gcc
+hash -r g++
+gcc --version
+cd qt-everywhere-opensource-src-5.9.1
+make -j2
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+
+ stage('install qt') {
+ result = sh returnStatus: true, script: '''
+export WORKSPACE=`cygpath $WORKSPACE`
+TOP=`pwd`
+P=`cygpath $DSB_PKGS/x86-mingw64/msys/usr/bin`
+export PATH=$WORKSPACE/gcc-7.1.0/bin:$P
+hash -r gcc
+hash -r g++
+gcc --version
+cd qt-everywhere-opensource-src-5.9.1
+make -i install
+'''
+ if (result != 0) {
+ echo '[FAILURE] Failed to build'
+ currentBuild.result = 'FAILURE'
+ sh "exit ${result}"
+ }
+ }
+}
+
diff --git a/buildqt32.bat b/buildqt32.bat
index 7f975cd..4fcc5d3 100755
--- a/buildqt32.bat
+++ b/buildqt32.bat
@@ -1,9 +1,17 @@
-rem @echo off
+@echo off
SET BASEDIR=%~dp0
-SET SDKDIR=z:\VS2019BT\
-SET PERLDIR=z:\Perl64\
+if not defined SDKDIR (
+ echo SDKDIR is not defined.
+ exit /b 1
+)
+if not defined PERLDIR (
+ echo SDKDIR is not defined.
+ exit /b 1
+)
+rem SET SDKDIR=z:\VS2019BT\
+rem SET PERLDIR=z:\Perl64\
SET QT_VERSION=5.12
SET QT_RELEASE=3
@@ -61,4 +69,4 @@ call nmake
call nmake install
cd %PREFIX%
%BASEDIR%wintools\7za.exe a -tzip %BASEDIR%\qt-%QT_VERSION%-%INST_ARCH%.zip .\*
-cd %BASEDIR% \ No newline at end of file
+cd %BASEDIR%
diff --git a/buildqt64.bat b/buildqt64.bat
index b4e0fca..f158c16 100755
--- a/buildqt64.bat
+++ b/buildqt64.bat
@@ -2,8 +2,17 @@
SET BASEDIR=%~dp0
-SET SDKDIR=z:\VS2019BT
-SET PERLDIR=z:\Perl64
+IF NOT DEFINED SDKDIR (
+ ECHO SDKDIR is not defined.
+ EXIT /b 1
+)
+IF NOT DEFINED PERLDIR (
+ ECHO SDKDIR is not defined.
+ EXIT /b 1
+)
+
+REM SET SDKDIR=z:\VS2019BT
+REM SET PERLDIR=z:\Perl64
SET QT_VERSION=5.12
SET QT_RELEASE=3
@@ -59,4 +68,4 @@ call nmake
call nmake install
cd %PREFIX%
%BASEDIR%wintools\7za.exe a -tzip %BASEDIR%\qt-%QT_VERSION%-%INST_ARCH%.zip .\*
-cd %BASEDIR% \ No newline at end of file
+cd %BASEDIR%