Fix problem when calling "gnulib-tool --update" on multiple directories.
authorBruno Haible <bruno@clisp.org>
Thu, 31 Aug 2006 13:11:23 +0000 (13:11 +0000)
committerBruno Haible <bruno@clisp.org>
Thu, 31 Aug 2006 13:11:23 +0000 (13:11 +0000)
ChangeLog
gnulib-tool

index 895d3294070438075bfeca97abb8f30286310b26..e94d891d21fb2bb32f7dadacb0601f2c5a9ade7a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-08-31  Bruno Haible  <bruno@clisp.org>
+
+       * gnulib-tool: When calling func_import more than once, do it in a
+       subshell.
+       Reported by Eric Blake <ebb9@byu.net>.
+
 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
 
        * modules/nanosleep (Depends-on): Add gettime.
index 361201c0751127de30dcc65b560c31c7ed1e81aa..8dcd8eeb0e28a99c69cc47d85c495497f7745faf 100755 (executable)
@@ -22,7 +22,7 @@
 
 progname=$0
 package=gnulib
-cvsdatestamp='$Date: 2006-08-30 18:13:34 $'
+cvsdatestamp='$Date: 2006-08-31 13:11:23 $'
 last_checkin_date=`echo "$cvsdatestamp" | sed -e 's,^\$[D]ate: ,,'`
 version=`echo "$last_checkin_date" | sed -e 's/ .*$//' -e 's,/,-,g'`
 
@@ -2417,7 +2417,12 @@ case $mode in
           if test $# = 0; then
             # No further arguments. Guess the user wants to update all of them.
             for m4base in $m4dirs; do
-              func_import
+              # Perform func_import in a subshell, so that variable values
+              # such as
+              #   local_gnulib_dir, avoidlist, sourcebase, m4base, docbase,
+              #   testsbase, libname, lgpl, makefile_name, libtool, macro_prefix
+              # don't propagate from one directory to another.
+              (func_import) || exit 1
             done
           else
             # Really ambiguous.