Patches welcome? Here's mine.
License: Public domain.

--- gen_build_files.sh  2010-05-17 22:00:34.912406823 +0200
+++ gen_build_files_fixed.sh    2010-05-17 22:03:33.893406743 +0200
@@ -1,5 +1,6 @@
 #!/bin/sh
-# bashism:
+# bashism removed:
+# lines 22 and 48 had
 # "read -r" without variable name reads line into $REPLY
 # without stripping whitespace.

@@ -18,9 +19,9 @@

                s=`sed -n 's...@^//kbuild:@@p' -- "$srctree/$d"/*.c`
                echo "# DO NOT EDIT. This file is generated from Kbuild.src" 
>"$dst.$$.tmp"
-               while read -r; do
-                       test x"$REPLY" = x"INSERT" && REPLY="$s"
-                       printf "%s\n" "$REPLY"
+               while read -r reply; do
+                       test x"$reply" = x"INSERT" && reply="$s"
+                       printf "%s\n" "$reply"
                done <"$src" >>"$dst.$$.tmp"

                if test -f "$dst" && cmp -s "$dst.$$.tmp" "$dst"; then
@@ -38,9 +39,9 @@

                s=`sed -n 's...@^//config:@@p' -- "$srctree/$d"/*.c`
                echo "# DO NOT EDIT. This file is generated from Config.src" 
>"$dst.$$.tmp"
-               while read -r; do
-                       test x"$REPLY" = x"INSERT" && REPLY="$s"
-                       printf "%s\n" "$REPLY"
+               while read -r reply; do
+                       test x"$reply" = x"INSERT" && reply="$s"
+                       printf "%s\n" "$reply"
                done <"$src" >>"$dst.$$.tmp"

                if test -f "$dst" && cmp -s "$dst.$$.tmp" "$dst"; then

(also attached)
It's easy, isn't it? ;)

Attachment: teh_patch_for_gen_build_files
Description: Binary data

_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to