@@ -136,6 +136,14 @@ if [[ -n "${ARCH_NATIVE-}" ]]; then
136136 {
137137 ! " $tini " 2>&1
138138 } | grep -q " more verbose"
139+
140+ echo " Testing $tini with: -- true (should succeed)"
141+ " ${tini} " -vvv -- true
142+
143+ echo " Testing $tini with: -- -- true (should fail)"
144+ if " ${tini} " -vvv -- -- true ; then
145+ exit 1
146+ fi
139147 fi
140148
141149 echo " Testing ${tini} supports TINI_VERBOSITY"
@@ -164,7 +172,12 @@ if [[ -n "${ARCH_NATIVE-}" ]]; then
164172 fi
165173
166174 echo " Checking hardening on $tini "
167- hardening-check --nopie --nostackprotector --nobindnow " ${tini} "
175+ hardening_skip=(--nopie --nostackprotector --nobindnow)
176+ if [[ " $CC " == " musl-gcc" ]]; then
177+ # FORTIFY_SOURCE is a glibc thing
178+ hardening_skip=(" ${hardening_skip[@]} " --nofortify)
179+ fi
180+ hardening-check " ${hardening_skip[@]} " " ${tini} "
168181 done
169182
170183 # Quick package audit
@@ -193,7 +206,7 @@ if [[ -n "${ARCH_NATIVE-}" ]]; then
193206 export CFLAGS # We need them to build our test suite, regardless of FORCE_SUBREAPER
194207
195208 # Install test dependencies
196- pip install psutil python-prctl bitmap
209+ CC=gcc pip install psutil python-prctl bitmap
197210
198211 # Run tests
199212 python " ${SOURCE_DIR} /test/run_inner_tests.py"
@@ -218,9 +231,7 @@ for tini in tini tini-static; do
218231 to=" ${DIST_DIR} /${tini} -${ARCH_SUFFIX} "
219232 TINIS+=(" $to " )
220233 cp " ${BUILD_DIR} /${tini} " " $to "
221- fi
222-
223- if [[ -n " ${ARCH_NATIVE-} " ]]; then
234+ else
224235 to=" ${DIST_DIR} /${tini} "
225236 TINIS+=(" $to " )
226237 cp " ${BUILD_DIR} /${tini} " " $to "
@@ -235,9 +246,7 @@ if [[ -n "${ARCH_NATIVE-}" ]]; then
235246 to=" ${DIST_DIR} /tini_${pkg_version} -${ARCH_SUFFIX} .${pkg_format} "
236247 TINIS+=(" $to " )
237248 cp " $src " " $to "
238- fi
239-
240- if [[ -n " ${ARCH_NATIVE-} " ]]; then
249+ else
241250 to=" ${DIST_DIR} /tini_${pkg_version} .${pkg_format} "
242251 TINIS+=(" $to " )
243252 cp " $src " " $to "
0 commit comments