[Pkg-xen-devel] [PATCH 04/12] debian/rules: Adjust boot shuffling script for POSIX
Elliott Mitchell
ehem+debian at m5p.com
Fri Jul 17 20:05:25 BST 2020
Often /bin/sh is distinctly faster than Bash, so move to the better
interpreter. Simplify variable usage to conform.
Signed-off-by: Elliott Mitchell <ehem+debian at m5p.com>
---
debian/shuffle-boot-files | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/debian/shuffle-boot-files b/debian/shuffle-boot-files
index f7492c0c72..8e4ed7e64c 100755
--- a/debian/shuffle-boot-files
+++ b/debian/shuffle-boot-files
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
set -e
@@ -26,6 +26,7 @@ verstring=$(readlink debian/tmp/boot/xen.gz ||
verstring=${verstring##*/}
verstring=${verstring%.gz}
-for f in `cd $t/boot && find * -type f -print`; do
- cp -v $t/boot/$f $dest/${f/$verstring/xen-$version-$flavour}
+find "$t/boot" -type f -print | while read f
+do
+ cp -v "$f" "$dest${f#$t/boot}"
done
--
(\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/)
\BS ( | ehem+sigmsg at m5p.com PGP 87145445 | ) /
\_CS\ | _____ -O #include <stddisclaimer.h> O- _____ | / _/
8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445
More information about the Pkg-xen-devel
mailing list