From: Adrian Schmutzler Date: Wed, 24 Jul 2019 22:51:27 +0000 (+0200) Subject: treewide: replace backticks by $(...) in gen_*_img.sh scripts X-Git-Tag: v21.02.0-rc1~4909 X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=c5b4fa20fadbdc47264a9c1f76d7b9351c42e7ec;p=openwrt%2Fopenwrt.git treewide: replace backticks by $(...) in gen_*_img.sh scripts This replaces deprecated backticks by more versatile $(...) syntax. Signed-off-by: Adrian Schmutzler [decapitalized patch subject at submitter's request] Signed-off-by: Christian Lamparter --- diff --git a/target/linux/apm821xx/image/mbl_gen_hdd_img.sh b/target/linux/apm821xx/image/mbl_gen_hdd_img.sh index 6536ce9872..1fb868b5b3 100755 --- a/target/linux/apm821xx/image/mbl_gen_hdd_img.sh +++ b/target/linux/apm821xx/image/mbl_gen_hdd_img.sh @@ -15,7 +15,7 @@ ROOTFSSIZE="$5" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 4096 -t 83 -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 4096 -t 83 -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/arc770/image/gen_axs10x_sdcard_img.sh b/target/linux/arc770/image/gen_axs10x_sdcard_img.sh index 9a6f93d0d9..3cbd2caceb 100755 --- a/target/linux/arc770/image/gen_axs10x_sdcard_img.sh +++ b/target/linux/arc770/image/gen_axs10x_sdcard_img.sh @@ -22,7 +22,7 @@ ROOTFSSIZE="$5" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/archs38/image/gen_axs10x_sdcard_img.sh b/target/linux/archs38/image/gen_axs10x_sdcard_img.sh index 9a6f93d0d9..3cbd2caceb 100755 --- a/target/linux/archs38/image/gen_axs10x_sdcard_img.sh +++ b/target/linux/archs38/image/gen_axs10x_sdcard_img.sh @@ -22,7 +22,7 @@ ROOTFSSIZE="$5" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/at91/image/gen_at91_sdcard_img.sh b/target/linux/at91/image/gen_at91_sdcard_img.sh index 316ecea2e4..4eb30fa790 100755 --- a/target/linux/at91/image/gen_at91_sdcard_img.sh +++ b/target/linux/at91/image/gen_at91_sdcard_img.sh @@ -22,7 +22,7 @@ ROOTFSSIZE="$5" head=4 sect=2048 -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/brcm2708/image/gen_rpi_sdcard_img.sh b/target/linux/brcm2708/image/gen_rpi_sdcard_img.sh index ffe01fa32c..60b66c3724 100755 --- a/target/linux/brcm2708/image/gen_rpi_sdcard_img.sh +++ b/target/linux/brcm2708/image/gen_rpi_sdcard_img.sh @@ -15,7 +15,7 @@ ROOTFSSIZE="$5" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 4096 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 4096 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/gemini/image/dns313_gen_hdd_img.sh b/target/linux/gemini/image/dns313_gen_hdd_img.sh index 1eb2c7c575..6e899ec840 100755 --- a/target/linux/gemini/image/dns313_gen_hdd_img.sh +++ b/target/linux/gemini/image/dns313_gen_hdd_img.sh @@ -17,7 +17,7 @@ sect=63 # Create two empty partitions followed by the boot partition with # the ./boot/zImage and then the rootfs partition. -set `ptgen -o $OUTPUT -h $head -s $sect -t 83 -n -p 0 -p 0 -p ${BOOTFSSIZE}M -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -t 83 -n -p 0 -p 0 -p ${BOOTFSSIZE}M -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/layerscape/image/gen_sdcard_head_img.sh b/target/linux/layerscape/image/gen_sdcard_head_img.sh index dc1efbb3e0..c7ecbb6883 100755 --- a/target/linux/layerscape/image/gen_sdcard_head_img.sh +++ b/target/linux/layerscape/image/gen_sdcard_head_img.sh @@ -19,4 +19,4 @@ ROOTFSSIZE="$3" head=4 sect=16 -set `ptgen -o $OUTPUT -h $head -s $sect -l $ROOTFSOFFSET -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l $ROOTFSOFFSET -t 83 -p ${ROOTFSSIZE}M) diff --git a/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh b/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh index e0230e48b6..100a9a96e5 100755 --- a/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh +++ b/target/linux/mvebu/image/gen_mvebu_sdcard_img.sh @@ -56,7 +56,7 @@ sect=63 # create real partition table using fdisk printf "Creating partition table: " -set `ptgen -o "$OUTFILE" -h $head -s $sect -l 1024 -S 0x$SIGNATURE $ptgen_args` +set $(ptgen -o "$OUTFILE" -h $head -s $sect -l 1024 -S 0x$SIGNATURE $ptgen_args) printf "Done\n" # install bootloader diff --git a/target/linux/mxs/image/gen_sdcard_ext4_ext4.sh b/target/linux/mxs/image/gen_sdcard_ext4_ext4.sh index 5653ba892f..99bd3bf573 100755 --- a/target/linux/mxs/image/gen_sdcard_ext4_ext4.sh +++ b/target/linux/mxs/image/gen_sdcard_ext4_ext4.sh @@ -21,7 +21,7 @@ head=4 sect=63 # set the Boot stream partition size to 1M -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t 53 -p 1M -t 83 -p ${ROOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t 53 -p 1M -t 83 -p ${ROOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) ROOTFS1OFFSET="$(($3 / 512))" ROOTFS1SIZE="$(($4 / 512))" diff --git a/target/linux/mxs/image/gen_sdcard_vfat_ext4.sh b/target/linux/mxs/image/gen_sdcard_vfat_ext4.sh index 616639d237..bca664c780 100755 --- a/target/linux/mxs/image/gen_sdcard_vfat_ext4.sh +++ b/target/linux/mxs/image/gen_sdcard_vfat_ext4.sh @@ -23,7 +23,7 @@ head=4 sect=63 # Set the u-boot storage to 2M -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t 53 -p 2M -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t 53 -p 2M -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) UBOOTOFFSET="$(($1 / 512))" UBOOTSIZE="$(($2 / 512))" diff --git a/target/linux/omap/image/gen_omap_sdcard_img.sh b/target/linux/omap/image/gen_omap_sdcard_img.sh index c2f2aaddf4..881df9a05d 100755 --- a/target/linux/omap/image/gen_omap_sdcard_img.sh +++ b/target/linux/omap/image/gen_omap_sdcard_img.sh @@ -22,7 +22,7 @@ ROOTFSSIZE="$5" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))" diff --git a/target/linux/rb532/image/gen_image.sh b/target/linux/rb532/image/gen_image.sh index a2d6f4012a..a9d48d86ca 100755 --- a/target/linux/rb532/image/gen_image.sh +++ b/target/linux/rb532/image/gen_image.sh @@ -9,7 +9,7 @@ ALIGN="$6" rm -f "$OUTPUT" # create partition table -set `ptgen -o "$OUTPUT" -h 16 -s 32 -l ${ALIGN} -t 0x27 -p ${KERNELSIZE}m -t 0x83 -p ${ROOTFSSIZE}m` +set $(ptgen -o "$OUTPUT" -h 16 -s 32 -l ${ALIGN} -t 0x27 -p ${KERNELSIZE}m -t 0x83 -p ${ROOTFSSIZE}m) KERNELOFFSET="$(($1 / 512))" ROOTFSOFFSET="$(($3 / 512))" diff --git a/target/linux/sunxi/image/gen_sunxi_sdcard_img.sh b/target/linux/sunxi/image/gen_sunxi_sdcard_img.sh index bb89e3a0fc..0d4a56d0d2 100755 --- a/target/linux/sunxi/image/gen_sunxi_sdcard_img.sh +++ b/target/linux/sunxi/image/gen_sunxi_sdcard_img.sh @@ -22,7 +22,7 @@ UBOOT="$6" head=4 sect=63 -set `ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M` +set $(ptgen -o $OUTPUT -h $head -s $sect -l 1024 -t c -p ${BOOTFSSIZE}M -t 83 -p ${ROOTFSSIZE}M) BOOTOFFSET="$(($1 / 512))" BOOTSIZE="$(($2 / 512))"