# HG changeset patch # User Pascal Bellard # Date 1223663494 0 # Node ID 143fe275fe64b62f84016a5ea34987f8eebee75a # Parent 512988521ab9e92e882b489bc7b16a92eb614ba1 Add build-depends subcommand diff -r 512988521ab9 -r 143fe275fe64 tazwok --- a/tazwok Sun Oct 05 23:41:46 2008 +0000 +++ b/tazwok Fri Oct 10 18:31:34 2008 +0000 @@ -87,6 +87,7 @@ \033[1mCommands: \033[0m\n usage Print this short usage. stats Print Tazwok statistics from the config file and the wok. + build-depends Generate a list of package to build wok. cmp|compare Compare the wok and the cooked pkgs (--remove old pkgs). list List all packages in the wok tree or by category. info Get information about a package in the wok. @@ -647,6 +648,25 @@ ================================================================================" echo "" ;; + build-depends) + # List dependancies to rebuild wok + cd $WOK + ALL_DEPS="slitaz-toolchain" + echo $ALL_DEPS + for pkg in $(ls $2) + do + [ -f $pkg/receipt ] || continue + BUILD_DEPENDS="" + . $pkg/receipt + for i in $BUILD_DEPENDS; do + case " $ALL_DEPS " in + *\ $i\ *);; + *) ALL_DEPS="$ALL_DEPS $i" + echo $i;; + esac + done + done + ;; check) # Check wok consistancy echo "" @@ -722,6 +742,7 @@ ================================================================================" for pkg in $WOK/* do + WANTED="" . $pkg/receipt echo "$PACKAGE-$VERSION.tazpkg" >> /tmp/wok.list.$$ tpkg="$(ls $PACKAGES_REPOSITORY/$PACKAGE-$VERSION*.tazpkg 2> /dev/null)" @@ -745,6 +766,9 @@ fi fi if [ "$2" = "--cook" ]; then + if [ -n "$WANTED" -a ! -d $WOK/$WANTED/taz ]; then + yes '' | tazwok cook $WANTED + fi yes '' | tazwok cook $PACKAGE fi done