Control: tags -1 + patch Hello Christoph,
On Sat, Dec 08, 2018 at 08:50:21PM +0100, Christoph Berg wrote: [...] > The variables are probably not used widely, but replacing the > `findbin` calls by the static text they are supposed to output is a > pretty easy fix, so I'd opt to do that. Thanks for your speedy feedback. Patch attached. Regards, Andreas Henriksson
diff -Nru xymon-4.3.28/debian/changelog xymon-4.3.28/debian/changelog --- xymon-4.3.28/debian/changelog 2018-01-19 02:45:18.000000000 +0100 +++ xymon-4.3.28/debian/changelog 2018-12-08 21:26:12.000000000 +0100 @@ -1,3 +1,10 @@ +xymon (4.3.28-3.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Add debian/patches/90_reproducible-build.patch (Closes: #915957) + + -- Andreas Henriksson <andr...@fatal.se> Sat, 08 Dec 2018 21:26:12 +0100 + xymon (4.3.28-3) unstable; urgency=medium * Switch from prename/perl to file-rename/rename in diff -Nru xymon-4.3.28/debian/patches/90_reproducible-build.patch xymon-4.3.28/debian/patches/90_reproducible-build.patch --- xymon-4.3.28/debian/patches/90_reproducible-build.patch 1970-01-01 01:00:00.000000000 +0100 +++ xymon-4.3.28/debian/patches/90_reproducible-build.patch 2018-12-08 21:26:12.000000000 +0100 @@ -0,0 +1,49 @@ +From: Andreas Henriksson <andr...@fatal.se> +Subject: fix reproducible build on merged-usr vs non-merged systems + +https://bugs.debian.org/915957 + +--- a/build/bb-commands.sh ++++ b/build/bb-commands.sh +@@ -7,36 +7,25 @@ + # includes these commands so that extension scripts can run from + # xymonserver.cfg without having to do special setups. + +-findbin() { +- MYP="`echo ${PATH} | sed -e 's/:/ /g'`" +- +- for D in $MYP +- do +- if test -x $D/$1; then +- echo "${D}/${1}" +- fi +- done +-} +- + echo "" + echo "# The following defines a bunch of commands that BB extensions expect to be present." + echo "# Xymon does not use them, but they are provided here so if you use BB extension" + echo "# scripts, then they will hopefully run without having to do a lot of tweaking." + echo "" +-for CMD in uptime awk cat cp cut date egrep expr find grep head id ln ls mv rm sed sort tail top touch tr uniq who ++for CMD in /usr/bin/uptime /usr/bin/awk /bin/cat /bin/cp /usr/bin/cut /bin/date /bin/egrep /usr/bin/expr /usr/bin/find /bin/grep /usr/bin/head /usr/bin/id /bin/ln /bin/ls /bin/mv /bin/rm /bin/sed /usr/bin/sort /usr/bin/tail /usr/bin/top /bin/touch /usr/bin/tr /usr/bin/uniq /usr/bin/who + do +- ENVNAME=`echo $CMD | tr "[a-z]" "[A-Z]"` +- PGM=`findbin $CMD | head -n 1` ++ ENVNAME=`echo $(basename $CMD) | tr "[a-z]" "[A-Z]"` ++ PGM="$CMD" + echo "${ENVNAME}=\"${PGM}\"" + done + + # WC is special +-PGM=`findbin wc | head -n 1` ++PGM="/usr/bin/wc" + echo "WC=\"${PGM} -l\"" + echo "WCC=\"${PGM}\"" + + # DFCMD is an alias for DF +-PGM=`findbin df | head -n 1` ++PGM="/bin/df" + echo "# DF,DFCMD and PS are for compatibility only, NOT USED by the Xymon client" + echo "DF=\"${PGM} -Pk\"" + echo "DFCMD=\"${PGM} -Pk\"" diff -Nru xymon-4.3.28/debian/patches/series xymon-4.3.28/debian/patches/series --- xymon-4.3.28/debian/patches/series 2018-01-18 16:50:00.000000000 +0100 +++ xymon-4.3.28/debian/patches/series 2018-12-08 21:21:28.000000000 +0100 @@ -18,3 +18,4 @@ 69_disk-no-duplicate-root.patch 84_fix_compilation_on_GNU_Hurd.patch 87_fix_logfetch_FTBFS_with_glibc_2.26.patch +90_reproducible-build.patch