[Qa-jenkins-scm] [jenkins.debian.net] 02/02: reproducible coreboot: add variations of PATH, umask and kernel version

Holger Levsen holger at moszumanska.debian.org
Sun Jun 7 12:13:50 UTC 2015


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch master
in repository jenkins.debian.net.

commit a813a6f122905e422155a02ee4d3b2d63ad5143c
Author: Holger Levsen <holger at layer-acht.org>
Date:   Sun Jun 7 14:13:26 2015 +0200

    reproducible coreboot: add variations of PATH, umask and kernel version
---
 TODO                         |  3 +--
 bin/reproducible_common.sh   |  6 +++---
 bin/reproducible_coreboot.sh | 12 ++++++++++--
 3 files changed, 14 insertions(+), 7 deletions(-)

diff --git a/TODO b/TODO
index 5d35199..aff7a66 100644
--- a/TODO
+++ b/TODO
@@ -226,8 +226,7 @@ egrep -R -l '(debbindiff had trouble comparing|maybe there is still )' /var/lib/
 	<mapreri> that would be wonderful.
 
 * coreboot
-** add more variations: domain+hostname, PATH, uid+gid, USER, UTS namespace, kernel version, umask
-** clone with https?
+** add more variations: domain+hostname, uid+gid, USER, UTS namespace
 
 * openwrt
 ----
diff --git a/bin/reproducible_common.sh b/bin/reproducible_common.sh
index b7400ad..ee30e83 100755
--- a/bin/reproducible_common.sh
+++ b/bin/reproducible_common.sh
@@ -263,9 +263,9 @@ write_explaination_table() {
 	write_page "<tr><td>env TZ</td><td>TZ=\"/usr/share/zoneinfo/Etc/GMT+12\"</td><td>TZ=\"/usr/share/zoneinfo/Etc/GMT-14\"</td></tr>"
 	write_page "<tr><td>env LANG</td><td>LANG=\"en_GB.UTF-8\"</td><td>LANG=\"fr_CH.UTF-8\"</td></tr>"
 	write_page "<tr><td>env LC_ALL</td><td><em>unset</em></td><td>LC_ALL=\"fr_CH.UTF-8\"</td></tr>"
+	write_page "<tr><td>env PATH</td><td>PATH=\"/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:\"</td><td>PATH=\"/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path\"</td></tr>"
 	local NUM_CPU=$(cat /proc/cpuinfo |grep '^processor'|wc -l)
 	if [ "$1" = "debian" ] ; then
-		write_page "<tr><td>env PATH</td><td>PATH=\"/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:\"</td><td>PATH=\"/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path\"</td></tr>"
 		write_page "<tr><td>env BUILDUSERID</td><td>BUILDUSERID=\"1111\"</td><td>BUILDUSERID=\"2222\"</td></tr>"
 		write_page "<tr><td>env BUILDUSERNAME</td><td>BUILDUSERNAME=\"pbuilder1\"</td><td>BUILDUSERNAME=\"pbuilder2\"</td></tr>"
 		write_page "<tr><td>env USER</td><td>USER=\"pbuilder1\"</td><td>USER=\"pbuilder2\"</td></tr>"
@@ -273,9 +273,9 @@ write_explaination_table() {
 		write_page "<tr><td>gid</td><td>gid=1111</td><td>gid=2222</td></tr>"
 		write_page "<tr><td>env DEB_BUILD_OPTIONS</td><td>DEB_BUILD_OPTIONS=\"parallel=$NUM_CPU\"</td><td>DEB_BUILD_OPTIONS=\"parallel=$(echo $NUM_CPU-1|bc)\"<br />(using a different number of cores is on the agenda)</td></tr>"
 		write_page "<tr><td>UTS namespace</td><td><em>shared with the host</em></td><td><em>modified using</em> /usr/bin/unshare --uts</td></tr>"
-		write_page "<tr><td>kernel version, modified using /usr/bin/linux64 --uname-2.6</td><td>$(uname -sr)</td><td>$(/usr/bin/linux64 --uname-2.6 uname -sr)</td></tr>"
-		write_page "<tr><td>umask</td><td>0022<td>0002</td><tr>"
 	fi
+	write_page "<tr><td>kernel version, modified using /usr/bin/linux64 --uname-2.6</td><td>$(uname -sr)</td><td>$(/usr/bin/linux64 --uname-2.6 uname -sr)</td></tr>"
+	write_page "<tr><td>umask</td><td>0022<td>0002</td><tr>"
 	write_page "<tr><td>CPU type</td><td>$(cat /proc/cpuinfo|grep 'model name'|head -1|cut -d ":" -f2-)</td><td>same for both builds (currently, work in progress)</td></tr>"
 	write_page "<tr><td>year, month, date</td><td>today ($DATE)</td><td>same for both builds (currently, work in progress)</td></tr>"
 	write_page "<tr><td>hour, minute</td><td>hour is usually the same...</td><td>usually, the minute differs... (currently, work in progress)</td></tr>"
diff --git a/bin/reproducible_coreboot.sh b/bin/reproducible_coreboot.sh
index d33d7a1..ebc315e 100755
--- a/bin/reproducible_coreboot.sh
+++ b/bin/reproducible_coreboot.sh
@@ -118,7 +118,8 @@ NUM_CPU=$(cat /proc/cpuinfo |grep '^processor'|wc -l)
 sed -i "s#cpus=1#cpus=$NUM_CPU#" util/abuild/abuild
 sed -i 's#USE_XARGS=1#USE_XARGS=0#g' util/abuild/abuild
 # actually build everything
-nice ionice -c 3 bash util/abuild/abuild || true # don't fail the full job just because some targets fail
+nice ionice -c 3 \
+	bash util/abuild/abuild || true # don't fail the full job just because some targets fail
 
 cd coreboot-builds
 for i in * ; do
@@ -136,14 +137,21 @@ echo "==========================================================================
 export TZ="/usr/share/zoneinfo/Etc/GMT-14"
 export LANG="fr_CH.UTF-8"
 export LC_ALL="fr_CH.UTF-8"
+export PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path"
+umask 0002
 # use allmost all cores for second build
 NEW_NUM_CPU=$(echo $NUM_CPU-1|bc)
 sed -i "s#cpus=$NUM_CPU#cpus=$NEW_NUM_CPU#" util/abuild/abuild
-nice ionice -c 3 bash util/abuild/abuild || true # don't fail the full job just because some targets fail
+nice ionice -c 3 \
+	linux64 --uname-2.6 \
+	bash util/abuild/abuild || true # don't fail the full job just because some targets fail
 
+# reset environment to default values again
 export LANG="en_GB.UTF-8"
 unset LC_ALL
 export TZ="/usr/share/zoneinfo/UTC"
+export PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:"
+umask 0022
 
 cd coreboot-builds
 for i in * ; do

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git



More information about the Qa-jenkins-scm mailing list