cookutils rev 706
Add (re)cookall.sh
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Mar 04 10:15:40 2015 +0100 (2015-03-04) |
parents | 64d82abb86f6 |
children | fe2e335b9100 |
files | cookall.sh |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/cookall.sh Wed Mar 04 10:15:40 2015 +0100 1.3 @@ -0,0 +1,51 @@ 1.4 +#!/bin/sh 1.5 + 1.6 +DONELIST=${1:-/tmp/donelist} 1.7 + 1.8 +. /home/slitaz/wok/slitaz-toolchain/receipt 1.9 +SLITAZ_TOOLCHAIN="slitaz-toolchain $DEPENDS" 1.10 +touch $DONELIST 1.11 +while true; do 1.12 + chmod +x $DONELIST 1.13 + for i in /home/slitaz/wok/*/receipt ; do 1.14 + grep -q "^$(basename ${i%/receipt})$" $DONELIST && continue 1.15 + unset BUILD_DEPENDS WANTED 1.16 + . $i 1.17 + for j in $BUILD_DEPENDS $WANTED ; do 1.18 + case " $SLITAZ_TOOLCHAIN " in 1.19 + *\ $j\ *) continue ;; 1.20 + esac 1.21 + grep -q "^$j$" $DONELIST || continue 2 1.22 + done 1.23 + cooker pkg $PACKAGE 1.24 + [ /home/slitaz/packages/$PACKAGE-$VERSION*.tazpkg -nt $DONELIST ] || continue 1.25 + echo $PACKAGE >> $DONELIST 1.26 + chmod -x $DONELIST 1.27 + done 1.28 + [ -x $DONELIST ] || continue 1.29 + # try to break build dep loops... 1.30 + for i in gettext python udev cups libQtClucene menu-cache ; do 1.31 + grep -q "^$i$" $DONELIST && continue 1.32 + . /home/slitaz/wok/$i/receipt 1.33 + cooker pkg $PACKAGE 1.34 + [ /home/slitaz/packages/$PACKAGE-$VERSION*.tazpkg -nt $DONELIST ] || continue 1.35 + echo $PACKAGE >> $DONELIST 1.36 + continue 2 1.37 + done 1.38 + break 1.39 +done 1.40 + 1.41 +TODOLIST=/tmp/todolist 1.42 +# list packages to build and their (build) dependancies 1.43 +for i in /home/slitaz/wok/*/receipt ; do 1.44 + grep -q "^$(basename ${i%/receipt})$" $DONELIST && continue 1.45 + unset BUILD_DEPENDS WANTED 1.46 + . $i 1.47 + echo -n "$PACKAGE : " 1.48 + for j in $BUILD_DEPENDS $WANTED ; do 1.49 + grep -q "^$j$" $DONELIST || echo -n "$j " 1.50 + done 1.51 + echo 1.52 +done > $TODOLIST 1.53 +echo "$(wc -l $TODOLIST) packages unbuilt in $TODOLIST" 1.54 +