diff options
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/reproducible_coreboot.sh | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/bin/reproducible_coreboot.sh b/bin/reproducible_coreboot.sh index c672a8bf..19841f8f 100755 --- a/bin/reproducible_coreboot.sh +++ b/bin/reproducible_coreboot.sh @@ -115,8 +115,8 @@ nice ionice -c 3 \ cd coreboot-builds for i in * ; do + mkdir $TMPDIR/b1/$i if [ -f $i/coreboot.rom ] ; then - mkdir $TMPDIR/b1/$i cp -p $i/coreboot.rom $TMPDIR/b1/$i/ fi done @@ -184,30 +184,37 @@ cat > $PAGE <<- EOF </center></p> EOF write_page " <h1>Reproducible Coreboot</h1>" -write_page " <p><em>This is work in progress started on 2015-06-04.</em>" +write_page " <p><em>This is work in progress started on 2015-06-04.</em></p>" write_page " <p><em>Reproducible builds</em> enable anyone to reproduce bit by bit identical binary packages from a given source. There is a lot more information about <a href=\"https://wiki.debian.org/ReproducibleBuilds\">reproducible builds on the Debian wiki</a> and on <a href=\"https://reproducible.debian.net\">https://reproducible.debian.net</a>.</p>" write_page " <p><em>Reproducible Coreboot</em> is an effort to apply this to coreboot. Thus each coreboot.rom is build twice, with a few varitations added and then those two ROMs are compared using <a href=\"https://tracker.debian.org/debbindiff\">debbindiff</a>.</p>" write_page " <p>This set up to test the <code>master</code> branch of <a href=\"https://review.coreboot.org/p/coreboot.git\">coreboot.git</a> monthly, but as this is brand new, currently updates are triggered much more often. Patches are very much welcome, the coreboot pages are solely generated by <a href=\"http://anonscm.debian.org/cgit/qa/jenkins.debian.net.git/tree/bin/reproducible_coreboot.sh\">reproducible_coreboot.sh</a>.</p>" write_page " <p>These tests were last run on $DATE for version ${COREBOOT_VERSION}.</p><p><code>$(echo -n '$COREBOOT')</code></p>" write_explaination_table coreboot write_page " <ul>" -ROMS=0 -RROMS=0 +BAD_ROMS=0 +GOOD_ROMS=0 +ALL_ROMS=0 create_results_dirs cd b1 for i in * ; do - let ROMS+=1 - call_debbindiff $i - if [ -f $TMPDIR/$i.html ] ; then - mv $TMPDIR/$i.html $BASE/coreboot/dbd/$i.html - write_page " <li><a href=\"dbd/$i.html\"><img src=\"/userContent/static/weather-showers-scattered.png\" alt=\"unreproducible icon\" /> $i</a> is unreproducible.</li>" + let ALL_ROMS+=1 + if [ -f $i/coreboot.rom ] ; then + call_debbindiff $i + if [ -f $TMPDIR/$i.html ] ; then + mv $TMPDIR/$i.html $BASE/coreboot/dbd/$i.html + write_page " <li><a href=\"dbd/$i.html\"><img src=\"/userContent/static/weather-showers-scattered.png\" alt=\"unreproducible icon\" /> $i</a> is unreproducible.</li>" + else + write_page " <li><img src=\"/userContent/static/weather-clear.png\" alt=\"reproducible icon\" /> $i had no debbindiff output so it's probably reproducible :)</li>" + let GOOD_ROMS+=1 + fi else - write_page " <li><img src=\"/userContent/static/weather-clear.png\" alt=\"reproducible icon\" />$i had no debbindiff output so its probably reproducible :)</li>" - let RROMS+=1 + write_page " <li><img src=\"/userContent/static/weather-storm.png\" alt=\"FTBFS icon\" /> $i failed to build from source.</li>" + let BAD_ROMS+=1 fi done -PERCENT=$(echo "scale=1 ; ($RROMS*100/$ROMS)" | bc) -write_page " </ul><p>$RROMS ($PERCENT%) out of $ROMS built coreboot images were reproducible.</p>" +GOOD_PERCENT=$(echo "scale=1 ; ($GOOD_ROMS*100/$ALL_ROMS)" | bc) +BAD_PERCENT=$(echo "scale=1 ; ($BAD_ROMS*100/$ALL_ROMS)" | bc) +write_page " </ul><p>$GOOD_ROMS ($GOOD_PERCENT%) out of $ALL_ROMS built coreboot images were reproducible, while $BAD_ROMS ($BAD_PERCENT%) failed to built from source.</p>" cat >> $PAGE <<- EOF </div> </div> |