On Sun, Jul 01, 2012 at 03:13:57PM -0400, Milan Kupcevic wrote: > +if grep -q CONFIG_RD_XZ=y /boot/config-$release ; then > + is_xz_supported=Yes > +fi >
Have a look at this test statement > +if test "$is_xz_supported"; then > + XZ="xz --check=crc32 -8" > +else > + XZ=false > +fi And have a look at these test statements: > + test -z "$verbose" || echo === Creating compressed initrd image > - if test "`od -A n -c -N 2 $initrd`" = " 037 213"; then > + if test "`xxd -p -l2 $initrd`" = "1f8b"; then > + test -z "$verbose" || echo === $initrd is already gzip compressed > + if test -n "$is_xz_supported" && test "$arch" != "prep"; then > + test -z "$verbose" || echo === recompressing to xz > + elif test "`xxd -p -l6 $initrd`" = "fd377a585a00"; then > + test -z "$verbose" || echo === $initrd is already xz compressed > + test -z "$verbose" || echo === assuming $initrd was not compressed Notices that those tests are either test string = otherstring or are test --option "$variable" They here again a "test --option $variable" and a strange looking single "test $variable" > > @@ -317,7 +334,11 @@ > WRAPPER=$objdir/wrapper > vmlinuz=$work/vmlinuz.$arch > if test -n "$initrd"; then > - INITRD="-i $work/initrd.gz" > + if test "$is_xz_supported"; then > + INITRD="-i $work/initrd.xz" > + else > + INITRD="-i $work/initrd.gz" > + fi > fi > $WRAPPER -c -o $vmlinuz -p $arch $INITRD -D $objdir -W $work $kernel > else Please use the more readable test -n "$is_xz_supported" Groeten Geert Stappers -- > And is there a policy on top-posting vs. bottom-posting? Yes.
signature.asc
Description: Digital signature