Date:2009-12-01 07:52:56 (10 years 6 months ago)
Author:xiangfu
Commit:3265f82de2ca233b4e7ef9ecf4892c2931ccbd1c
Message:998-openwrt_lzma_options.patch

Files: scripts/Makefile.lib (1 diff)
scripts/gen_initramfs_list.sh (3 diffs)

Change Details

scripts/Makefile.lib
228228
229229quiet_cmd_lzma = LZMA $@
230230cmd_lzma = (cat $(filter-out FORCE,$^) | \
231    lzma -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \
231    lzma -lc1 -lp2 -pb2 -eos -si -so && $(call size_append, $(filter-out FORCE,$^))) > $@ || \
232232    (rm -f $@ ; false)
scripts/gen_initramfs_list.sh
225225output="/dev/stdout"
226226output_file=""
227227is_cpio_compressed=
228compr="gzip -9 -f"
228compr="gzip -9 -f -"
229229
230230arg="$1"
231231case "$arg" in
...... 
239239        output_file="$1"
240240        cpio_list="$(mktemp ${TMPDIR:-/tmp}/cpiolist.XXXXXX)"
241241        output=${cpio_list}
242        echo "$output_file" | grep -q "\.gz$" && compr="gzip -9 -f"
243        echo "$output_file" | grep -q "\.bz2$" && compr="bzip2 -9 -f"
244        echo "$output_file" | grep -q "\.lzma$" && compr="lzma -9 -f"
242        echo "$output_file" | grep -q "\.gz$" && compr="gzip -9 -f -"
243        echo "$output_file" | grep -q "\.bz2$" && compr="bzip2 -9 -f -"
244        echo "$output_file" | grep -q "\.lzma$" && compr="lzma e -lc1 -lp2 -pb2 -eos -si -so"
245245        echo "$output_file" | grep -q "\.cpio$" && compr="cat"
246246        shift
247247        ;;
...... 
292292    if [ "${is_cpio_compressed}" = "compressed" ]; then
293293        cat ${cpio_tfile} > ${output_file}
294294    else
295        (cat ${cpio_tfile} | ${compr} - > ${output_file}) \
295        (cat ${cpio_tfile} | ${compr} > ${output_file}) \
296296        || (rm -f ${output_file} ; false)
297297    fi
298298    [ -z ${cpio_file} ] && rm ${cpio_tfile}

Archive Download the corresponding diff file



interactive