tazwok rev 460 4.3

tazwok: various fixes about packages_db() generation
author Antoine Bodin <gokhlayeh@slitaz.org>
date Fri Mar 25 17:58:40 2011 +0100 (2011-03-25)
parents 95e4c4e04cdd
children ae0a39ba004a
files tazwok
line diff
     1.1 --- a/tazwok	Wed Mar 16 19:02:11 2011 +0100
     1.2 +++ b/tazwok	Fri Mar 25 17:58:40 2011 +0100
     1.3 @@ -1364,9 +1364,9 @@
     1.4  
     1.5  	# If $packages_repository is the main one, configure few functions
     1.6  	# to act as they should, without having loop on them (speed-up)
     1.7 -	if [ "${pkg_repository##*/}" = packages ]; then
     1.8 +	if [ "$pkg_repository" = "$PACKAGES_REPOSITORY" ]; then
     1.9  		erase_package_info_extracmd="erase_package_info_main"
    1.10 -		get_packages_info_extracmd="erase_package_info_main"
    1.11 +		get_packages_info_extracmd="get_packages_info_main"
    1.12  	fi
    1.13  }
    1.14  
    1.15 @@ -1447,8 +1447,7 @@
    1.16  {
    1.17  	[ "$WANTED" ] && echo -e "$PACKAGE\t$WANTED" >> wanted.txt
    1.18  	echo -e "$PACKAGE\t "$DEPENDS" \t "$BUILD_DEPENDS" " >> package.txt
    1.19 -	libs=$(grep -m1 ^$PACKAGE$'\t' $lib_db | cut -f 2)
    1.20 -	[ "$libs" ] && echo "$libs" >> libraries.txt
    1.21 +	grep -m1 ^$PACKAGE$'\t' $lib_db >> libraries.txt
    1.22  }
    1.23  
    1.24  source_receipt()
    1.25 @@ -1476,9 +1475,11 @@
    1.26  			[ -f $file ] || continue
    1.27  			sort -o $file $file
    1.28  		done
    1.29 -		md5sum packages.md5 | cut -f1 -d' ' > ID
    1.30  		report end-step
    1.31  	fi
    1.32 +
    1.33 +	md5sum packages.md5 | cut -f1 -d' ' > ID
    1.34 +	[ -s ID ] || echo null > ID
    1.35  	
    1.36  	# Dont log this because lzma always output errors.
    1.37  	lzma e files.list files.list.lzma