@@ -32,19 +32,19 @@ build:
32
32
# Run Salsa-CI .build-before-script equivalent
33
33
- mkdir -p ${WORKING_DIR} ${CCACHE_WORK_DIR}
34
34
- mv ${CCACHE_WORK_DIR} ${CCACHE_TMP_DIR}
35
- # Run Salsa-CI .build-script equivalent
36
- - export CCACHE_DIR=" ${CCACHE_TMP_DIR}"
37
- - apt-get update && eatmydata apt-get install --yes -- no-install-recommends aptitude devscripts ccache equivs
35
+ # Run Salsa-CI .build-script equivalent, with extra devscripts so autobake-deb.sh can run 'dch'
36
+ - export CCACHE_DIR=${CCACHE_TMP_DIR}
37
+ - apt-get update && eatmydata apt-get install --no-install-recommends -y ccache fakeroot build-essential devscripts
38
38
- cd ${WORKING_DIR}/${SOURCE_DIR}
39
- - eatmydata install- build-deps.sh .
39
+ - eatmydata apt-get build-dep --no-install-recommends -y .
40
40
- update-ccache-symlinks; ccache -z # Zero out ccache counters
41
41
- while true; do sleep 600; echo "10 minutes passed" >&2; done & # Progress keeper since build is long and silent
42
42
- debian/autobake-deb.sh |& tail -n 10000 # Keep Gitlab-CI output under 4 MB
43
43
- cd ${WORKING_DIR}
44
44
- rm -rf ${WORKING_DIR}/${SOURCE_DIR}
45
45
- du -shc ${WORKING_DIR}/* # Show total file size of artifacts. Must stay are under 100 MB.
46
46
- ccache -s # Show ccache stats to validate it worked
47
- - mv ${CCACHE_TMP_DIR} ${CCACHE_WORK_DIR} || true
47
+ - mv ${CCACHE_TMP_DIR} ${CCACHE_WORK_DIR}
48
48
49
49
build bullseye-backports :
50
50
extends : .build-package
@@ -77,45 +77,6 @@ build i386:
77
77
78
78
build native deb :
79
79
extends : .build-package
80
- script : &buildpackage-script |
81
- mkdir -p ${WORKING_DIR} ${CCACHE_WORK_DIR}
82
- mv ${CCACHE_WORK_DIR} ${CCACHE_TMP_DIR}
83
- export CCACHE_DIR=${CCACHE_TMP_DIR}
84
- # Add deb-src entries
85
- sed -n '/^deb\s/s//deb-src /p' /etc/apt/sources.list > /etc/apt/sources.list.d/deb-src.list
86
- apt-get update && eatmydata apt-get install --no-install-recommends -y \
87
- aptitude \
88
- devscripts \
89
- ccache \
90
- equivs \
91
- build-essential \
92
- python3
93
- # Enter source package dir
94
- cd ${WORKING_DIR}/${SOURCE_DIR}
95
- # Install package build dependencies
96
- eatmydata install-build-deps.sh .
97
- # Generate ccache links
98
- dpkg-reconfigure ccache
99
- PATH="/usr/lib/ccache/:${PATH}"
100
- # Reset ccache stats
101
- ccache -z
102
- # Create salsaci user and fix permissions
103
- useradd salsaci
104
- chown -R salsaci. ${WORKING_DIR} ${CCACHE_DIR}
105
- # Define buildlog filename
106
- BUILD_LOGFILE_SOURCE=$(dpkg-parsechangelog -S Source)
107
- BUILD_LOGFILE_VERSION=$(dpkg-parsechangelog -S Version)
108
- BUILD_LOGFILE_VERSION=${BUILD_LOGFILE_VERSION#*:}
109
- BUILD_LOGFILE_ARCH=$(dpkg --print-architecture)
110
- BUILD_LOGFILE="${WORKING_DIR}/${BUILD_LOGFILE_SOURCE}_${BUILD_LOGFILE_VERSION}_${BUILD_LOGFILE_ARCH}.build"
111
- # Build package as user salsaci
112
- su salsaci -c "eatmydata dpkg-buildpackage ${DB_BUILD_PARAM}" |& OUTPUT_FILENAME=${BUILD_LOGFILE} filter-output
113
- # Restore PWD to ${WORKING_DIR}
114
- cd ${WORKING_DIR}
115
- rm -rf ${WORKING_DIR}/${SOURCE_DIR}
116
- # Print ccache stats on job log
117
- ccache -s
118
- mv ${CCACHE_TMP_DIR} ${CCACHE_WORK_DIR}
119
80
120
81
piuparts :
121
82
extends : .test-piuparts
0 commit comments