From 00ae28f2e8c659ba2848c1a12683bed483f31c08 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Fri, 10 Oct 2014 12:58:44 +0200 Subject: reproducible: polishing various little things --- bin/reproducible_build.sh | 2 ++ bin/reproducible_setup.sh | 2 +- bin/reproducible_stats.sh | 12 +++++++----- 3 files changed, 10 insertions(+), 6 deletions(-) (limited to 'bin') diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh index abb142a0..c999fe00 100755 --- a/bin/reproducible_build.sh +++ b/bin/reproducible_build.sh @@ -158,6 +158,8 @@ for SRCPACKAGE in ${PACKAGES} ; do RBUILDLOG=/var/lib/jenkins/userContent/rbuild/${SRCPACKAGE}_${EVERSION}.rbuild.log mv ${TMPLOG} ${RBUILDLOG} # check whether the package is not for us... + # FIXME: needs to check for all packages, not just the first one + # FIXME: linux-any is valid too (but hurd-any not) ARCH=$(grep "^Architecture: " ${SRCPACKAGE}_*.dsc| sort -r | head -1 | cut -d " " -f2-) if [[ ! "$ARCH" =~ "amd64" ]] && [[ ! "$ARCH" =~ "all" ]] && [[ ! "$ARCH" =~ "any" ]] && [[ ! "$ARCH" =~ "linux-amd64" ]]; then sqlite3 -init $INIT ${PACKAGES_DB} "REPLACE INTO source_packages VALUES (\"${SRCPACKAGE}\", \"${VERSION}\", \"not for us\", \"$DATE\")" diff --git a/bin/reproducible_setup.sh b/bin/reproducible_setup.sh index 1ee7cbee..35d35989 100755 --- a/bin/reproducible_setup.sh +++ b/bin/reproducible_setup.sh @@ -35,7 +35,7 @@ EOF # blacklist some packages for PKG in linux cups zurl openclipart ; do - RESULT=$(sqlite3 -init $INIT $PACKAGES_DB " SELECT name FROM source_packages WHERE status = 'blacklisted' AND name = '$PGK'") + RESULT=$(sqlite3 -init $INIT $PACKAGES_DB " SELECT name FROM source_packages WHERE status = 'blacklisted' AND name = '$PKG'") if [ "$RESULT" = "" ] ; then sqlite3 -init $INIT $PACKAGES_DB "REPLACE into source_packages VALUES ('$PKG','0','blacklisted',date('now'))" fi diff --git a/bin/reproducible_stats.sh b/bin/reproducible_stats.sh index fbdf85a3..5e2d7336 100755 --- a/bin/reproducible_stats.sh +++ b/bin/reproducible_stats.sh @@ -71,6 +71,8 @@ SPOKENTARGET["FTBFS"]="packages which failed to build from source" SPOKENTARGET["404"]="packages where the sources failed to downloaded" SPOKENTARGET["not_for_us"]="packages which should not be build on 'amd64'" SPOKENTARGET["blacklisted"]="packages which have been blacklisted" +# shop trailing slash +JENKINS_URL=${JENKINS_URL:0:-1} # # gather notes @@ -276,7 +278,7 @@ EOF set_icon() { # icons taken from tango-icon-theme (0.8.90-5) # licenced under http://creativecommons.org/licenses/publicdomain/ - STATE_TARGET_NAME=$1 + STATE_TARGET_NAME="$1" case "$1" in reproducible) ICON=weather-clear.png ;; @@ -292,7 +294,7 @@ set_icon() { ;; 404) ICON=weather-severe-alert.png ;; - not_for_us) ICON=weather-few-clouds-night.png + not*) ICON=weather-few-clouds-night.png ;; blacklisted) ICON=error.png ;; @@ -399,7 +401,7 @@ write_summary_header() { if [ "$1" = "$MAINVIEW" ] ; then write_summary "

These pages are updated every six hours. Results are obtained from several build jobs running on jenkins.debian.net. Thanks to Profitbricks for donating the virtual machine it's running on!

" fi - write_summary "

$COUNT_TOTAL packages attempted to build so far, that's $PERCENT_TOTAL% of $AMOUNT source packages in Debian $SUITE currently. Out of these, $PERCENT_GOOD% were successful, so quite wildly guessing this roughy means about $GUESS_GOOD packages should be reproducibly buildable!" + write_summary "

$COUNT_TOTAL packages have been attempted to be build so far, that's $PERCENT_TOTAL% of $AMOUNT source packages in Debian $SUITE currently. Out of these, $PERCENT_GOOD% were successful, so quite wildly guessing this roughy means about $GUESS_GOOD packages should be reproducibly buildable!" if [ "${1:0:3}" = "all" ] || [ "$1" = "dd-list" ] ; then write_summary " Join #debian-reproducible on OFTC to get support for making sure your packages build reproducibly too!" fi @@ -426,7 +428,7 @@ write_summary_header() { } write_summary_footer() { - write_summary "


Static URL for this page. Last modified: $(date). Copyright 2014 Holger Levsen, GPL-2 licensed. About jenkins.debian.net. Weather icons are taken from the Tango Icon Library." + write_summary "


About jenkins.debian.net, about reproducible builds of Debian and overview of reproducible build results on jenkins.d.n. Last update: $(date). Copyright 2014 Holger Levsen, GPL-2 licensed. The weather icons are public domain and have been taken from the Tango Icon Library." write_summary "

" } @@ -579,4 +581,4 @@ for STATE in $ALLSTATES ; do publish_summary done -echo "Enjoy https://jenkins.debian.net/userContent/reproducible.html" +echo "Enjoy $JENKINS_URL/userContent/reproducible.html" -- cgit v1.2.3-70-g09d2