Skip to content
Snippets Groups Projects
Verified Commit 988c1e94 authored by Mattia Rizzolo's avatar Mattia Rizzolo
Browse files

reproducible debian: build: support old stretch's diffoscope that doesn't take --timeout

parent 79f9cf00
No related branches found
No related tags found
No related merge requests found
......@@ -333,7 +333,7 @@ diffoscope_timed_out() {
}
call_diffoscope_on_changes_files() {
local TMPLOG TIMEOUT TEMP MSG_PART1 session diffoscope_version
local TMPLOG TIMEOUT DIFFOSCOPE_TIMEOUT TEMP MSG_PART1 session diffoscope_version
# DIFFOSCOPE is globally used
# filter lines describing .buildinfo files from .changes file
sed -i -e '/^ [a-f0-9]\{32,64\} .*\.buildinfo$/d' b{1,2}/$CHANGES
......@@ -368,15 +368,18 @@ call_diffoscope_on_changes_files() {
# we have a working diffoscope!
log_info "$DIFFOSCOPE will be used to compare the two builds:"
if [ $(echo $DIFFOSCOPE_VERSION | awk '{print $2}') -ge 202 ]; then
# this --timeout 120m below is arbitrary and can be subject to further evaluation later
DIFFOSCOPE_TIMEOUT="--timeout $(( 120 * 60 ))"
fi
set -x
set +e
# the --timeout 120m below is arbitrary and can be subject to further evaluation later
( timeout 155m nice schroot \
--directory $TMPDIR \
--run-session \
-c "$session" \
-- sh -c "export TMPDIR=$TEMP ; timeout $TIMEOUT diffoscope \
--timeout $(( 120 * 60 )) \
${DIFFOSCOPE_TIMEOUT-} \
--html $TMPDIR/${DBDREPORT} \
--text $TMPDIR/$DBDTXT \
--json $TMPDIR/$DBDJSON \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment