automake-commit
[Top][All Lists]
Advanced

[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-180-g00c3eb2
Date: Sat, 13 Sep 2008 10:22:47 +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=00c3eb2317235c2b851cdc7c4faf18ed83d7fba2

The branch, master has been updated
       via  00c3eb2317235c2b851cdc7c4faf18ed83d7fba2 (commit)
      from  7726a26a5337ae0215f77295503ecd7b21369f2a (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 00c3eb2317235c2b851cdc7c4faf18ed83d7fba2
Author: Ralf Wildenhues <address@hidden>
Date:   Sat Sep 13 09:55:23 2008 +0200

    install: cope with non-injective $(transform).
    
    * lib/am/progs.am (install-%DIR%PROGRAMS): Rewrite rule to not
    try to use the installed name as key in a hash, so destructive
    $(transform) scripts still work.
    * lib/am/scripts.am (install-%DIR%SCRIPTS): Likewise.
    * tests/transform.test: Fix test to look in right place for
    installed files.
    * tests/transform2.test: New test.
    * tests/Makefile.am: Adjust.
    Report by Jim Meyering.
    
    Signed-off-by: Ralf Wildenhues <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 Makefile.in           |   30 ++++----
 aclocal.m4            |    4 +-
 configure             |  208 +++++++++++++++++++++++++------------------------
 lib/am/progs.am       |   42 +++++-----
 lib/am/scripts.am     |   39 +++++-----
 tests/Makefile.am     |    1 +
 tests/Makefile.in     |    1 +
 tests/transform.test  |    5 +-
 tests/transform2.test |   82 +++++++++++++++++++
 9 files changed, 251 insertions(+), 161 deletions(-)
 create mode 100755 tests/transform2.test

diff --git a/Makefile.in b/Makefile.in
index 5ece957..1a33103 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -298,22 +298,20 @@ install-binSCRIPTS: $(bin_SCRIPTS)
        sed -e 'p;s,.*/,,;n' \
            -e 'h;s|.*|.|' \
            -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \
-       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = ""; list[""] = "" } { \
-         if ($$2 == $$4) tgt = $$3; else tgt = $$3 "/" $$4; \
-         files[tgt] = files[tgt] " " $$1; dirs[$$3] = 1; \
-         if (++n[tgt] == $(am__install_max)) \
-           { list[++lno] = tgt " " files[tgt]; n[tgt] = 0; files[tgt] = "" } } 
\
-         END { d = ""; for (dir in dirs) d = d " " dir; print d; \
-               for (l in list) print list[l]; \
-               for (dir in files) print dir, files[dir] }' | { \
-       read dirs; \
-       while read dir files; do \
-         if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
-         test -z "$$files" || { \
-           echo " $(binSCRIPT_INSTALL) $$files '$(DESTDIR)$(bindir)$$dir'"; \
-           $(binSCRIPT_INSTALL) $$files "$(DESTDIR)$(bindir)$$dir" || exit 
$$?; \
-         }; \
-       done; }
+       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \
+         { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+           if ($$2 == $$4) { files[d] = files[d] " " $$1; \
+             if (++n[d] == $(am__install_max)) { \
+               print "f", d, files[d]; n[d] = 0; files[d] = "" } } \
+           else { print "f", d "/" $$4, $$1 } } \
+         END { for (d in files) print "f", d, files[d] }' | \
+       while read type dir files; do \
+            if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+            test -z "$$files" || { \
+              echo " $(binSCRIPT_INSTALL) $$files '$(DESTDIR)$(bindir)$$dir'"; 
\
+              $(binSCRIPT_INSTALL) $$files "$(DESTDIR)$(bindir)$$dir" || exit 
$$?; \
+            } \
+       ; done
 
 uninstall-binSCRIPTS:
        @$(NORMAL_UNINSTALL)
diff --git a/aclocal.m4 b/aclocal.m4
index 16f8a30..b275e43 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -13,8 +13,8 @@
 
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.62],,
-[m4_warning([this file was generated for autoconf 2.62.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],,
+[m4_warning([this file was generated for autoconf 2.63.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 
`autoreconf'.])])
diff --git a/configure b/configure
index a6ded56..d7591c2 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.62 for GNU Automake 1.10a.
+# Generated by GNU Autoconf 2.63 for GNU Automake 1.10a.
 #
 # Report bugs to <address@hidden>.
 #
@@ -601,82 +601,82 @@ PACKAGE_STRING='GNU Automake 1.10a'
 PACKAGE_BUGREPORT='address@hidden'
 
 ac_unique_file="automake.in"
-ac_subst_vars='SHELL
-PATH_SEPARATOR
-PACKAGE_NAME
-PACKAGE_TARNAME
-PACKAGE_VERSION
-PACKAGE_STRING
-PACKAGE_BUGREPORT
-exec_prefix
-prefix
-program_transform_name
-bindir
-sbindir
-libexecdir
-datarootdir
-datadir
-sysconfdir
-sharedstatedir
-localstatedir
-includedir
-oldincludedir
-docdir
-infodir
-htmldir
-dvidir
-pdfdir
-psdir
-libdir
-localedir
-mandir
-DEFS
-ECHO_C
-ECHO_N
-ECHO_T
-LIBS
-build_alias
-host_alias
-target_alias
-build
-build_cpu
-build_vendor
-build_os
-am_AUTOCONF
-INSTALL_PROGRAM
-INSTALL_SCRIPT
-INSTALL_DATA
-am__isrc
-CYGPATH_W
-PACKAGE
-VERSION
-ACLOCAL
-AUTOCONF
-AUTOMAKE
-AUTOHEADER
-MAKEINFO
-install_sh
-STRIP
-INSTALL_STRIP_PROGRAM
-MKDIR_P
-mkdir_p
-AWK
-SET_MAKE
-am__leading_dot
-AMTAR
-am__tar
-am__untar
-APIVERSION
-pkgvdatadir
-PERL
-TEX
-LN
-MODIFICATION_DELAY
-GREP
-EGREP
-FGREP
+ac_subst_vars='LTLIBOBJS
 LIBOBJS
-LTLIBOBJS'
+FGREP
+EGREP
+GREP
+MODIFICATION_DELAY
+LN
+TEX
+PERL
+pkgvdatadir
+APIVERSION
+am__untar
+am__tar
+AMTAR
+am__leading_dot
+SET_MAKE
+AWK
+mkdir_p
+MKDIR_P
+INSTALL_STRIP_PROGRAM
+STRIP
+install_sh
+MAKEINFO
+AUTOHEADER
+AUTOMAKE
+AUTOCONF
+ACLOCAL
+VERSION
+PACKAGE
+CYGPATH_W
+am__isrc
+INSTALL_DATA
+INSTALL_SCRIPT
+INSTALL_PROGRAM
+am_AUTOCONF
+build_os
+build_vendor
+build_cpu
+build
+target_alias
+host_alias
+build_alias
+LIBS
+ECHO_T
+ECHO_N
+ECHO_C
+DEFS
+mandir
+localedir
+libdir
+psdir
+pdfdir
+dvidir
+htmldir
+infodir
+docdir
+oldincludedir
+includedir
+localstatedir
+sharedstatedir
+sysconfdir
+datadir
+datarootdir
+libexecdir
+sbindir
+bindir
+program_transform_name
+prefix
+exec_prefix
+PACKAGE_BUGREPORT
+PACKAGE_STRING
+PACKAGE_VERSION
+PACKAGE_TARNAME
+PACKAGE_NAME
+PATH_SEPARATOR
+SHELL'
 ac_subst_files=''
 ac_user_opts='
 enable_option_checking
@@ -1106,9 +1106,9 @@ fi
 if test -n "$ac_unrecognized_opts"; then
   case $enable_option_checking in
     no) ;;
-    fatal) { $as_echo "$as_me: error: Unrecognized options: 
$ac_unrecognized_opts" >&2
+    fatal) { $as_echo "$as_me: error: unrecognized options: 
$ac_unrecognized_opts" >&2
    { (exit 1); exit 1; }; } ;;
-    *)     $as_echo "$as_me: WARNING: Unrecognized options: 
$ac_unrecognized_opts" >&2 ;;
+    *)     $as_echo "$as_me: WARNING: unrecognized options: 
$ac_unrecognized_opts" >&2 ;;
   esac
 fi
 
@@ -1161,7 +1161,7 @@ test "$silent" = yes && exec 6>/dev/null
 ac_pwd=`pwd` && test -n "$ac_pwd" &&
 ac_ls_di=`ls -di .` &&
 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
-  { $as_echo "$as_me: error: Working directory cannot be determined" >&2
+  { $as_echo "$as_me: error: working directory cannot be determined" >&2
    { (exit 1); exit 1; }; }
 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
@@ -1373,7 +1373,7 @@ test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
 GNU Automake configure 1.10a
-generated by GNU Autoconf 2.62
+generated by GNU Autoconf 2.63
 
 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
@@ -1387,7 +1387,7 @@ This file contains any messages produced by compilers 
while
 running configure, to aid debugging if configure makes a mistake.
 
 It was created by GNU Automake $as_me 1.10a, which was
-generated by GNU Autoconf 2.62.  Invocation command line was
+generated by GNU Autoconf 2.63.  Invocation command line was
 
   $ $0 $@
 
@@ -1510,8 +1510,8 @@ _ASBOX
     case $ac_val in #(
     *${as_nl}*)
       case $ac_var in #(
-      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: Cache variable $ac_var 
contains a newline." >&5
-$as_echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var 
contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
       esac
       case $ac_var in #(
       _ | IFS | as_nl) ;; #(
@@ -1714,6 +1714,8 @@ $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
   fi
 done
 if $ac_cache_corrupted; then
+  { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise 
the build" >&5
 $as_echo "$as_me: error: changes in the environment can compromise the build" 
>&2;}
   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm 
$cache_file' and start over" >&5
@@ -2273,12 +2275,8 @@ fi
   else
     case $cross_compiling:$ac_tool_warned in
 yes:)
-{ $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect 
cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to address@hidden" >&5
-$as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to address@hidden" >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host 
triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" 
>&2;}
 ac_tool_warned=yes ;;
 esac
     STRIP=$ac_ct_STRIP
@@ -2780,8 +2778,8 @@ _ACEOF
     case $ac_val in #(
     *${as_nl}*)
       case $ac_var in #(
-      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: Cache variable $ac_var 
contains a newline." >&5
-$as_echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var 
contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
       esac
       case $ac_var in #(
       _ | IFS | as_nl) ;; #(
@@ -3209,7 +3207,7 @@ exec 6>&1
 # values after options handling.
 ac_log="
 This file was extended by GNU Automake $as_me 1.10a, which was
-generated by GNU Autoconf 2.62.  Invocation command line was
+generated by GNU Autoconf 2.63.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
   CONFIG_HEADERS  = $CONFIG_HEADERS
@@ -3222,6 +3220,12 @@ on `(hostname || uname -n) 2>/dev/null | sed 1q`
 
 _ACEOF
 
+case $ac_config_files in *"
+"*) set x $ac_config_files; shift; ac_config_files=$*;;
+esac
+
+
+
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 # Files that config.status was made for.
 config_files="$ac_config_files"
@@ -3233,14 +3237,15 @@ ac_cs_usage="\
 \`$as_me' instantiates files from templates according to the
 current configuration.
 
-Usage: $0 [OPTIONS] [FILE]...
+Usage: $0 [OPTION]... [FILE]...
 
   -h, --help       print this help, then exit
   -V, --version    print version number and configuration settings, then exit
-  -q, --quiet      do not print progress messages
+  -q, --quiet, --silent
+                   do not print progress messages
   -d, --debug      don't remove temporary files
       --recheck    update $as_me by reconfiguring in the same conditions
-  --file=FILE[:TEMPLATE]
+      --file=FILE[:TEMPLATE]
                    instantiate the configuration file FILE
 
 Configuration files:
@@ -3252,7 +3257,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_version="\\
 GNU Automake config.status 1.10a
-configured by $0, generated by GNU Autoconf 2.62,
+configured by $0, generated by GNU Autoconf 2.63,
   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; 
s/[\\""\`\$]/\\\\&/g'`\\"
 
 Copyright (C) 2008 Free Software Foundation, Inc.
@@ -3452,7 +3457,8 @@ for ac_last_try in false false false false false :; do
 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
    { (exit 1); exit 1; }; }
 
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` = 
$ac_delim_num; then
+  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
+  if test $ac_delim_n = $ac_delim_num; then
     break
   elif $ac_last_try; then
     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
@@ -3579,8 +3585,8 @@ do
   esac
   case $ac_mode$ac_tag in
   :[FHL]*:*);;
-  :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
-$as_echo "$as_me: error: Invalid tag $ac_tag." >&2;}
+  :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
+$as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
    { (exit 1); exit 1; }; };;
   :[FH]-) ac_tag=-:-;;
   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
@@ -3886,7 +3892,7 @@ if test "$no_create" != yes; then
   $ac_cs_success || { (exit 1); exit 1; }
 fi
 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; 
then
-  { $as_echo "$as_me:$LINENO: WARNING: Unrecognized options: 
$ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: Unrecognized options: $ac_unrecognized_opts" >&2;}
+  { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: 
$ac_unrecognized_opts" >&5
+$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
 fi
 
diff --git a/lib/am/progs.am b/lib/am/progs.am
index 28505cf..ea14053 100644
--- a/lib/am/progs.am
+++ b/lib/am/progs.am
@@ -47,29 +47,31 @@ install-%DIR%PROGRAMS: $(%DIR%_PROGRAMS)
            -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
        sed 'N;N;N;s,\n, ,g' | \
 ## The following awk script turns that into one line containing directories
-## and then lines of `target_name_or_directory sources...'.
-       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = "" } { \
-         if ($$2 == $$4) tgt = $$3; else tgt = $$3 "/" $$4; \
-         files[tgt] = files[tgt] " " $$1; dirs[$$3] = 1 } \
-         END { d=""; for (dir in dirs) d = d " " dir; print d; \
-               for (dir in files) print dir, files[dir] }' | { \
-       read dirs; \
-?!BASE?        for dir in $$dirs; do test . = $$dir || { \
-?!BASE?          echo " $(MKDIR_P) '$(DESTDIR)$(%NDIR%dir)/$$dir'"; \
-?!BASE?          $(MKDIR_P) "$(DESTDIR)$(%NDIR%dir)/$$dir" || exit $$?; \
-?!BASE?        }; done; \
-       while read dir files; do \
-         if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
-         test -z "$$files" || { \
-?!LIBTOOL?         echo " $(INSTALL_PROGRAM_ENV) $(%DIR%PROGRAMS_INSTALL) 
$$files '$(DESTDIR)$(%NDIR%dir)$$dir'"; \
-?!LIBTOOL?         $(INSTALL_PROGRAM_ENV) $(%DIR%PROGRAMS_INSTALL) $$files 
"$(DESTDIR)$(%NDIR%dir)$$dir" || exit $$?; \
+## and then lines of 'type target_name_or_directory sources...', with type
+## 'd' designating directories, and 'f' files.
+       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
+         { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+           if ($$2 == $$4) files[d] = files[d] " " $$1; \
+           else { print "f", $$3 "/" $$4, $$1; } } \
+         END { for (d in files) print "f", d, files[d] }' | \
+       while read type dir files; do \
+?!BASE?          case $$type in \
+?!BASE?          d) echo " $(MKDIR_P) '$(DESTDIR)$(%NDIR%dir)/$$dir'"; \
+?!BASE?             $(MKDIR_P) "$(DESTDIR)$(%NDIR%dir)/$$dir" || exit $$?;; \
+?!BASE?          f) \
+           if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+           test -z "$$files" || { \
+?!LIBTOOL?           echo " $(INSTALL_PROGRAM_ENV) $(%DIR%PROGRAMS_INSTALL) 
$$files '$(DESTDIR)$(%NDIR%dir)$$dir'"; \
+?!LIBTOOL?           $(INSTALL_PROGRAM_ENV) $(%DIR%PROGRAMS_INSTALL) $$files 
"$(DESTDIR)$(%NDIR%dir)$$dir" || exit $$?; \
 ## Note that we explicitly set the libtool mode.  This avoids any
 ## lossage if the install program doesn't have a name that libtool
 ## expects.
-?LIBTOOL?        echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) 
$(LIBTOOLFLAGS) --mode=install $(%DIR%PROGRAMS_INSTALL) $$files 
'$(DESTDIR)$(%NDIR%dir)$$dir'"; \
-?LIBTOOL?        $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) 
$(LIBTOOLFLAGS) --mode=install $(%DIR%PROGRAMS_INSTALL) $$files 
"$(DESTDIR)$(%NDIR%dir)$$dir" || exit $$?; \
-         }; \
-       done; }
+?LIBTOOL?          echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) 
$(LIBTOOLFLAGS) --mode=install $(%DIR%PROGRAMS_INSTALL) $$files 
'$(DESTDIR)$(%NDIR%dir)$$dir'"; \
+?LIBTOOL?          $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) 
$(LIBTOOLFLAGS) --mode=install $(%DIR%PROGRAMS_INSTALL) $$files 
"$(DESTDIR)$(%NDIR%dir)$$dir" || exit $$?; \
+           } \
+?!BASE?          ;; esac \
+       ; done
+
 endif %?INSTALL%
 
 
diff --git a/lib/am/scripts.am b/lib/am/scripts.am
index 6db83da..e4b61d1 100644
--- a/lib/am/scripts.am
+++ b/lib/am/scripts.am
@@ -48,26 +48,25 @@ install-%DIR%SCRIPTS: $(%DIR%_SCRIPTS)
 ?BASE?     -e 'h;s|.*|.|' \
 ?!BASE?            -e "s|$$srcdirstrip/||" -e 'h;s|[^/]*$$||; s|^$$|.|' \
            -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \
-       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = ""; list[""] = "" } { \
-         if ($$2 == $$4) tgt = $$3; else tgt = $$3 "/" $$4; \
-         files[tgt] = files[tgt] " " $$1; dirs[$$3] = 1; \
-         if (++n[tgt] == $(am__install_max)) \
-           { list[++lno] = tgt " " files[tgt]; n[tgt] = 0; files[tgt] = "" } } 
\
-         END { d = ""; for (dir in dirs) d = d " " dir; print d; \
-               for (l in list) print list[l]; \
-               for (dir in files) print dir, files[dir] }' | { \
-       read dirs; \
-?!BASE?        for dir in $$dirs; do test . = $$dir || { \
-?!BASE?          echo " $(MKDIR_P) '$(DESTDIR)$(%NDIR%dir)/$$dir'"; \
-?!BASE?          $(MKDIR_P) "$(DESTDIR)$(%NDIR%dir)/$$dir" || exit $$?; \
-?!BASE?        }; done; \
-       while read dir files; do \
-         if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
-         test -z "$$files" || { \
-           echo " $(%DIR%SCRIPT_INSTALL) $$files 
'$(DESTDIR)$(%NDIR%dir)$$dir'"; \
-           $(%DIR%SCRIPT_INSTALL) $$files "$(DESTDIR)$(%NDIR%dir)$$dir" || 
exit $$?; \
-         }; \
-       done; }
+       $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \
+         { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+           if ($$2 == $$4) { files[d] = files[d] " " $$1; \
+             if (++n[d] == $(am__install_max)) { \
+               print "f", d, files[d]; n[d] = 0; files[d] = "" } } \
+           else { print "f", d "/" $$4, $$1 } } \
+         END { for (d in files) print "f", d, files[d] }' | \
+       while read type dir files; do \
+?!BASE?          case $$type in \
+?!BASE?          d) echo " $(MKDIR_P) '$(DESTDIR)$(%NDIR%dir)/$$dir'"; \
+?!BASE?             $(MKDIR_P) "$(DESTDIR)$(%NDIR%dir)/$$dir" || exit $$?;; \
+?!BASE?          f) \
+            if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+            test -z "$$files" || { \
+              echo " $(%DIR%SCRIPT_INSTALL) $$files 
'$(DESTDIR)$(%NDIR%dir)$$dir'"; \
+              $(%DIR%SCRIPT_INSTALL) $$files "$(DESTDIR)$(%NDIR%dir)$$dir" || 
exit $$?; \
+            } \
+?!BASE?          ;; esac \
+       ; done
 endif %?INSTALL%
 
 
diff --git a/tests/Makefile.am b/tests/Makefile.am
index a9e995e..7146770 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -618,6 +618,7 @@ txinfo29.test \
 txinfo30.test \
 txinfo31.test \
 transform.test \
+transform2.test \
 unused.test \
 upc.test \
 upc2.test \
diff --git a/tests/Makefile.in b/tests/Makefile.in
index d5559b6..bac9382 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -769,6 +769,7 @@ txinfo29.test \
 txinfo30.test \
 txinfo31.test \
 transform.test \
+transform2.test \
 unused.test \
 upc.test \
 upc2.test \
diff --git a/tests/transform.test b/tests/transform.test
index 7a9e549..a5f4730 100755
--- a/tests/transform.test
+++ b/tests/transform.test
@@ -1,5 +1,6 @@
 #! /bin/sh
-# Copyright (C) 2002, 2003, 2004, 2007  Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2004, 2007, 2008  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
@@ -56,7 +57,7 @@ $AUTOMAKE
 $MAKE
 $MAKE test-install
 $MAKE uninstall
-test `find inst/foo -type f -print | wc -l` = 0
+test `find inst -type f -print | wc -l` = 0
 
 # Opportunistically test for installdirs.
 rm -rf inst
diff --git a/tests/transform2.test b/tests/transform2.test
new file mode 100755
index 0000000..f1faa94
--- /dev/null
+++ b/tests/transform2.test
@@ -0,0 +1,82 @@
+#! /bin/sh
+# Copyright (C) 2002, 2003, 2004, 2007, 2008  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
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# Make sure that --program-transform works even when multiple files are
+# collapsed.
+
+. ./defs || Exit 1
+
+set -e
+
+cat >>configure.in <<'END'
+AC_PROG_CC
+AC_OUTPUT
+END
+
+cat >Makefile.am <<'EOF'
+bin_PROGRAMS = p1 p2
+bin_SCRIPTS = s1.sh s2.sh
+man_MANS = m1.1 m2.1
+
+test-install: install
+       test -f inst/bin/p$(EXEEXT)
+       test -f inst/bin/s.sh
+       test -f inst/man/man1/m.1
+
+test-install-foo: install
+       test -f inst/bin/foo$(EXEEXT)
+       test -f inst/bin/foo
+       test -f inst/man/man1/foo.1
+       test ! -f inst/bin/p1$(EXEEXT)
+       test ! -f inst/bin/p2$(EXEEXT)
+       test ! -f inst/bin/s1.sh
+       test ! -f inst/bin/s2.sh
+       test ! -f inst/man/man/m1.1
+       test ! -f inst/man/man/m2.1
+EOF
+
+cat >p1.c <<'EOF'
+int
+main ()
+{
+  return 0;
+}
+EOF
+
+cp p1.c p2.c
+
+: > s1.sh
+: > s2.sh
+: > m1.1
+: > m2.1
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE
+
+./configure --program-transform-name='s/[12]//' --prefix "`pwd`/inst" --mandir 
"`pwd`/inst/man"
+$MAKE
+$MAKE test-install
+$MAKE uninstall
+test `find inst -type f -print | wc -l` = 0
+
+# Also squash all file types in question.
+./configure --program-transform-name='s/.*/foo/' --prefix "`pwd`/inst" 
--mandir "`pwd`/inst/man"
+$MAKE
+$MAKE test-install-foo
+$MAKE uninstall
+test `find inst -type f -print | wc -l` = 0
+:


hooks/post-receive
--
GNU Automake




reply via email to

[Prev in Thread] Current Thread [Next in Thread]