From 51216089bcd900fa9ec38c2bbb1014b36805041c Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Sat, 25 Oct 2003 21:49:51 +0000 Subject: [PATCH] * tests/output7.test: Populate sub/ with a dummy file, so that it is not empty. This fixes a failure reported by Patrick Welche. * lib/am/distdir.am: Add note about tar's `-o' option and empty directories. --- ChangeLog | 7 +++++++ lib/am/distdir.am | 7 +++++++ tests/output7.test | 12 ++++++++++++ 3 files changed, 26 insertions(+) diff --git a/ChangeLog b/ChangeLog index a05e5e6e8..d1fd476cd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2003-10-25 Alexandre Duret-Lutz + + * tests/output7.test: Populate sub/ with a dummy file, so that it + is not empty. This fixes a failure reported by Patrick Welche. + * lib/am/distdir.am: Add note about tar's `-o' option and empty + directories. + 2003-10-24 Didier Cassirame (tiny change) * lib/ylwrap: Typo in regex. diff --git a/lib/am/distdir.am b/lib/am/distdir.am index debc71b05..c269f4c4c 100644 --- a/lib/am/distdir.am +++ b/lib/am/distdir.am @@ -210,6 +210,13 @@ endif %?TOPDIR_P% ## Note that we don't use GNU tar's `-z' option. One reason (but not ## the only reason) is that some versions of tar (e.g., OSF1) ## interpret `-z' differently. +## +## The -o option of GNU tar used to exclude empty directories. This +## behavior was fixed in tar 1.12 (released on 1997-04-25). But older +## versions of tar are still used (for instance NetBSD 1.6.1 ships +## with tar 1.11.2). We do not do anything specific w.r.t. this +## incompatibility since packages where empty directories need to be +## present in the archive are really unusual. if %?TOPDIR_P% diff --git a/tests/output7.test b/tests/output7.test index eb9c65992..f26251cb6 100755 --- a/tests/output7.test +++ b/tests/output7.test @@ -43,6 +43,7 @@ all-local: EOF cat >mk/sub.am <<'EOF' +EXTRA_DIST = foo all-local: @echo in--sub EOF @@ -53,6 +54,17 @@ all-local: SUBDIRS = mk sub EOF +# We have to distribute something in foo, because some versions +# of tar do not archive empty directories when passed the `o' +# flags. (This was fixed in GNU tar 1.12, but older +# versions are still used: NetBSD 1.6.1 ships with tar 1.11.2). +# +# If sub/ is missing from the archive, config.status will fail +# to compute $ac_abs_srcdir during a VPATH build: config.status +# is able to create sub/ in the build tree, but it assumes the +# directory already exists in the source tree. +echo bar > sub/foo + $ACLOCAL $AUTOCONF $AUTOMAKE -- 2.47.2