]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
testsuite: do not change the mode of installed Libtool files.
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sat, 23 May 2009 21:05:17 +0000 (23:05 +0200)
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Sun, 24 May 2009 12:43:15 +0000 (14:43 +0200)
* tests/defs.in: Do not use `chmod -R' on the test directory, as
that may change or try to change the mode of installed files:
the test directory may contain symlinks to ltmain.sh files from
a Libtool installation, and Solaris `chmod -R' touches symlink
targets.  Instead, use the cleanup strategy used in distdir.am.
* NEWS: Update.
Report by Dagobert Michelsen.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
ChangeLog
NEWS
tests/defs.in

index cb0c44f15f776a1cc44e162bf3f300c25a0376fb..c20ffbcdeb94589d5f5bb9e389152c35528bb01d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
 2009-05-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
+       testsuite: do not change the mode of installed Libtool files.
+       * tests/defs.in: Do not use `chmod -R' on the test directory, as
+       that may change or try to change the mode of installed files:
+       the test directory may contain symlinks to ltmain.sh files from
+       a Libtool installation, and Solaris `chmod -R' touches symlink
+       targets.  Instead, use the cleanup strategy used in distdir.am.
+       * NEWS: Update.
+       Report by Dagobert Michelsen.
+
        testsuite: do not fail in cleanup code.
        * tests/defs.in: Turn off errexit in the cleanup trap, to avoid
        a test failure due to a nonzero command.
diff --git a/NEWS b/NEWS
index 20d5080d2d1cf8a6cc442a0288b4482106297483..48873d0302cf211a78fb965a50955fced476db75 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -10,6 +10,9 @@ Bugs fixed in 1.11.0a:
     `get_python_lib' function if it points outside the configured prefix,
     unless the `--prefix' argument was either `/usr' or below `/System'.
 
+  - The testsuite does not try to change the mode of `ltmain.sh' files from
+    a Libtool installation (symlinked to test directories) any more.
+
 \f
 New in 1.11:
 
index 7d74dd217e7f03ab8156e751168dc22573860fe2..0254d3afec118907b8dc8aebc54402d0fedb58cc 100644 (file)
@@ -247,8 +247,10 @@ Exit ()
 
 curdir=`pwd`
 testSubDir=$me.dir
-chmod -R u+rwx $testSubDir > /dev/null 2>&1
-rm -rf $testSubDir > /dev/null 2>&1
+test ! -d $testSubDir || {
+  find $testSubDir -type d ! -perm -200 -exec chmod u+w {} ";"
+  rm -rf $testSubDir
+}
 mkdir $testSubDir
 
 sh_errexit_works=@sh_errexit_works@
@@ -258,8 +260,9 @@ if test "$sh_errexit_works" = yes; then
     cd "$curdir"
     case $exit_status,$keep_testdirs in
     0,)
-      chmod -R a+rwx $testSubDir > /dev/null 2>&1
-      rm -rf "$testSubDir" ;;
+      find $testSubDir -type d ! -perm -200 -exec chmod u+w {} ";"
+      rm -rf $testSubDir
+      ;;
     esac
     test "$signal" != 0 &&
       echo "$as_me: caught signal $signal"