[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-commit] [SCM] GNU Automake branch, master, updated. Release-1-
From: |
Ralf Wildenhues |
Subject: |
[Automake-commit] [SCM] GNU Automake branch, master, updated. Release-1-10-280-g3a12ed5 |
Date: |
Sun, 22 Mar 2009 09:17:04 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Automake".
http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=3a12ed5e97dc193a38dd14e031658cbd329b50ca
The branch, master has been updated
via 3a12ed5e97dc193a38dd14e031658cbd329b50ca (commit)
from 04bb420a64c45f709bddea95c63fe0b2b35ad015 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 3a12ed5e97dc193a38dd14e031658cbd329b50ca
Author: Peter Breitenlohner <address@hidden>
Date: Sun Mar 22 10:11:14 2009 +0100
DISTFILES containing a directory and files in that directory.
For PR automake/533:
When the source tree contains non-writable files or directories
(as happens during distcheck), and directories or entries
thereof are listed multiple times in variables to be
distributed, then the corresponding directories below $(distdir)
need to be made writable recursively. Since file modes should
not change, they need to be copied recursively using `cp -f'.
* lib/am/distdir.am: Handle this situation.
* tests/distdir.test: Extend test to those cases.
* NEWS: Update.
Report by Peter Breitenlohner.
Signed-off-by: Ralf Wildenhues <address@hidden>
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 16 ++++++++++++++++
Makefile.in | 8 ++++++--
NEWS | 3 +++
doc/Makefile.in | 8 ++++++--
lib/Automake/Makefile.in | 8 ++++++--
lib/Automake/tests/Makefile.in | 8 ++++++--
lib/Makefile.in | 8 ++++++--
lib/am/Makefile.in | 8 ++++++--
lib/am/distdir.am | 10 ++++++++--
m4/Makefile.in | 8 ++++++--
tests/Makefile.in | 8 ++++++--
tests/distdir.test | 27 +++++++++++++++++++++++----
12 files changed, 98 insertions(+), 22 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index b6858c0..2d85e13 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+2009-03-22 Peter Breitenlohner <address@hidden>
+ Ralf Wildenhues <address@hidden>
+
+ For PR automake/533:
+ DISTFILES containing a directory and files in that directory.
+ When the source tree contains non-writable files or directories
+ (as happens during distcheck), and directories or entries
+ thereof are listed multiple times in variables to be
+ distributed, then the corresponding directories below $(distdir)
+ need to be made writable recursively. Since file modes should
+ not change, they need to be copied recursively using `cp -f'.
+ * lib/am/distdir.am: Handle this situation.
+ * tests/distdir.test: Extend test to those cases.
+ * NEWS: Update.
+ Report by Peter Breitenlohner.
+
2009-03-22 Jim Meyering <address@hidden>
Fix a documentation typo.
diff --git a/Makefile.in b/Makefile.in
index 4224570..7891cda 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -482,10 +482,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/NEWS b/NEWS
index a81b37b..780b49a 100644
--- a/NEWS
+++ b/NEWS
@@ -183,6 +183,9 @@ Bugs fixed in 1.10a:
- The default no-op recursive rules for these targets also work with BSD make
now: html, install-html, install-dvi, install-pdf, install-pdf,
install-info.
+ - `make distcheck' works also when both a directory and some file below it
+ have been added to a distribution variable, such as EXTRA_DIST or
*_SOURCES.
+
* Bugs introduced by 1.10:
- Fix output of dummy dependency files in presence of post-processed
diff --git a/doc/Makefile.in b/doc/Makefile.in
index befd9b1..fe0343a 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -555,10 +555,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/lib/Automake/Makefile.in b/lib/Automake/Makefile.in
index bae89fd..d03f25d 100644
--- a/lib/Automake/Makefile.in
+++ b/lib/Automake/Makefile.in
@@ -465,10 +465,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in
index b663fc4..85c4971 100644
--- a/lib/Automake/tests/Makefile.in
+++ b/lib/Automake/tests/Makefile.in
@@ -312,10 +312,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/lib/Makefile.in b/lib/Makefile.in
index 47d0c72..3aaab7e 100644
--- a/lib/Makefile.in
+++ b/lib/Makefile.in
@@ -440,10 +440,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/lib/am/Makefile.in b/lib/am/Makefile.in
index ea62647..c61b2bc 100644
--- a/lib/am/Makefile.in
+++ b/lib/am/Makefile.in
@@ -281,10 +281,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/lib/am/distdir.am b/lib/am/distdir.am
index 2f2d176..5ee7b5c 100644
--- a/lib/am/distdir.am
+++ b/lib/am/distdir.am
@@ -202,10 +202,16 @@ endif %?TOPDIR_P%
## directory exists only in $(srcdir), because some vendor Make (such
## as Tru64) will magically create an empty directory in `.'
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+## If the destination directory already exists, it may contain read-only
+## files, e.g., during `make distcheck'.
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
## Test for file existence because sometimes a file gets included in
## DISTFILES twice. For example this happens when a single source
diff --git a/m4/Makefile.in b/m4/Makefile.in
index f9f1adb..5b4eb23 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -278,10 +278,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/tests/Makefile.in b/tests/Makefile.in
index a491055..32744ba 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -990,10 +990,14 @@ distdir: $(DISTFILES)
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
+ fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
- cp -pR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx
{} \;; \
fi; \
- cp -pR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
diff --git a/tests/distdir.test b/tests/distdir.test
index 641a307..4c861bf 100755
--- a/tests/distdir.test
+++ b/tests/distdir.test
@@ -1,5 +1,6 @@
#! /bin/sh
-# Copyright (C) 1996, 2001, 2002, 2003, 2006, 2007 Free Software Foundation,
Inc.
+# Copyright (C) 1996, 2001, 2002, 2003, 2006, 2007, 2009 Free Software
+# Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -18,6 +19,8 @@
# sure *srcdir is properly handled. Note that using `./', as in
# EXTRA_DIST = ./joe
# does not work portably: it fails with HP-UX and Tru64 make.
+# Also test DISTFILES containing a directory and a file in it,
+# and repeated directories.
. ./defs || Exit 1
@@ -26,20 +29,36 @@ set -e
echo AC_OUTPUT >>configure.in
cat > Makefile.am << 'END'
-EXTRA_DIST = foo/bar joe $(top_srcdir)/woo/doo $(srcdir)/dada
+include_HEADERS = some/file another/sub/subsub/file2 yet/another/file3
+EXTRA_DIST = foo/bar joe $(top_srcdir)/woo/doo $(srcdir)/dada \
+ some another/sub yet \
+ some another/sub yet
+
+
+all-local:
+ $(MKDIR_P) another/sub/subsub
+ touch another/sub/subsub/file2
+
+CLEANFILES = another/sub/subsub/file2
+
check-local:
test -f $(srcdir)/foo/bar
test -f $(srcdir)/woo/doo
test -f $(srcdir)/joe
test -f $(srcdir)/dada
+ test -f $(srcdir)/some/file
+ test -f $(srcdir)/another/sub/subsub/file2 \
+ || test -f /another/sub/subsub/file2
+ test -f $(srcdir)/yet/another/file3
END
$ACLOCAL
$AUTOCONF
$AUTOMAKE
-mkdir foo woo
-touch foo/bar joe woo/doo dada
+mkdir foo woo some another another/sub another/sub/subsub yet yet/another
+touch foo/bar joe woo/doo dada some/file another/sub/subsub/file2
+touch yet/another/file3
mkdir build
cd build
hooks/post-receive
--
GNU Automake
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Automake-commit] [SCM] GNU Automake branch, master, updated. Release-1-10-280-g3a12ed5,
Ralf Wildenhues <=