diff options
author | Andrew Manison <amanison@anselsystems.com> | 2010-08-01 11:52:14 +0000 |
---|---|---|
committer | Andrew Manison <amanison@anselsystems.com> | 2010-08-01 11:52:14 +0000 |
commit | f3eb155dab5d8de075f99dee8bfe7a8bb750732c (patch) | |
tree | 72c53a399d7c8ced20cb4364f4154a1f548a290a /rebuild-alpine.sh | |
parent | 60b2a00006b281336d49ae0c72700e02c006c443 (diff) | |
download | aports-f3eb155dab5d8de075f99dee8bfe7a8bb750732c.tar.bz2 aports-f3eb155dab5d8de075f99dee8bfe7a8bb750732c.tar.xz |
build process: Added debug flag to rebuild-alpine.sh script.
Added debug flag to preserve build logs for packages that succeed, as well as
report installed packages before and after each build.
Diffstat (limited to 'rebuild-alpine.sh')
-rwxr-xr-x | rebuild-alpine.sh | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/rebuild-alpine.sh b/rebuild-alpine.sh index 20756bd9a5..b5d72f92bb 100755 --- a/rebuild-alpine.sh +++ b/rebuild-alpine.sh @@ -26,9 +26,14 @@ build () { pkgno=$(expr "$pkgno" + 1) echo "Building $p ($pkgno of $pktcnt in $1 - $failed failed)" cd $rootdir/$1/$p + if [ -n "$debug" ] ; then + apk info | sort > $rootdir/packages.$1.$pkgno.$p.before + fi abuild -rm > $rootdir/$1_$p.txt 2>&1 if [ "$?" = "0" ] ; then - rm $rootdir/$1_$p.txt + if [ -z "$debug" ] ; then + rm $rootdir/$1_$p.txt + fi else echo "Package $1/$p failed to build (output in $rootdir/$1_$p.txt)" if [ -n "$mail" ] ; then @@ -46,6 +51,9 @@ build () { fi failed=$(expr "$failed" + 1) fi + if [ -n "$debug" ] ; then + apk info | sort > $rootdir/packages.$1.$pkgno.$p.after + fi done cd $rootdir } @@ -54,10 +62,11 @@ touch START_OF_BUILD.txt unset clean unset mail -while getopts "cm" opt; do +while getopts "cmd" opt; do case $opt in 'c') clean="--clean";; 'm') mail="--mail";; + 'd') debug="--debug";; esac done |