use cached suffix value and if it is not valid, lets warn
authorMike Frysinger <vapier@gentoo.org>
Thu, 11 Jan 2007 22:30:19 +0000 (22:30 -0000)
committerMike Frysinger <vapier@gentoo.org>
Thu, 11 Jan 2007 22:30:19 +0000 (22:30 -0000)
svn path=/main/trunk/; revision=5576

bin/ecompressdir

index f6b7ed74d1ef298f33d68d5a2fb9e7a15f63c753..3f6fb251ec79a5861fe42b1b998a81fe349d1f98 100755 (executable)
@@ -10,7 +10,10 @@ fi
 
 # figure out the new suffix
 suffix=$(ecompress --suffix)
-[[ -z ${suffix} ]] && exit 0
+if [[ -z ${suffix} ]] ; then
+       vecho "${0##*/}: unable to figure out compressed suffix"
+       exit 1
+fi
 
 source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
 
@@ -25,7 +28,7 @@ for dir in "$@" ; do
                vecho "${0##*/}: $(ecompress --bin) ${dir#${D}}"
        fi
 
-       find "${dir}" -type f '!' -name '*'$(ecompress --suffix) -print0 | xargs -0 ecompress
+       find "${dir}" -type f '!' -name '*'${suffix} -print0 | xargs -0 ecompress
        ((ret+=$?))
        find -L "${dir}" -type l | \
        while read brokenlink ; do