]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
Merge branch 'minor'
authorMathieu Lirzin <mthl@gnu.org>
Thu, 31 Aug 2017 17:23:42 +0000 (19:23 +0200)
committerMathieu Lirzin <mthl@gnu.org>
Thu, 31 Aug 2017 17:23:42 +0000 (19:23 +0200)
1  2 
NEWS
bin/aclocal.in
bin/automake.in
bootstrap
configure.ac
doc/automake.texi
lib/Automake/local.mk
lib/texinfo.tex
m4/local.mk
maintainer/syntax-checks.mk
t/list-of-tests.mk

diff --cc NEWS
Simple merge
diff --cc bin/aclocal.in
Simple merge
diff --cc bin/automake.in
index 9c4cb869417a071a75238aae47c75a8130624ad2,3433d3de7c8316b9ea12c3183a192cc36e9197b3..62eb13fe5786eb84ff9e428a174a6dd71ec76b9b
@@@ -31,9 -31,17 +31,8 @@@ use strict
  
  BEGIN
  {
-   @Automake::perl_libdirs = ('@datadir@/@PACKAGE@-@APIVERSION@')
-     unless @Automake::perl_libdirs;
-   unshift @INC, @Automake::perl_libdirs;
+   unshift (@INC, '@datadir@/@PACKAGE@-@APIVERSION@')
+     unless $ENV{AUTOMAKE_UNINSTALLED};
 -
 -  # Override SHELL.  This is required on DJGPP so that system() uses
 -  # bash, not COMMAND.COM which doesn't quote arguments properly.
 -  # Other systems aren't expected to use $SHELL when Automake
 -  # runs, but it should be safe to drop the "if DJGPP" guard if
 -  # it turns up other systems need the same thing.  After all,
 -  # if SHELL is used, ./configure's SHELL is always better than
 -  # the user's SHELL (which may be something like tcsh).
 -  $ENV{'SHELL'} = '@SHELL@' if exists $ENV{'DJDIR'};
  }
  
  use Automake::Config;
@@@ -1637,14 -1771,48 +1704,47 @@@ sub handle_single_transfor
                # object.  In this case we rewrite the object's
                # name to ensure it is unique.
  
-               # We choose the name 'DERIVED_OBJECT' to ensure
-               # (1) uniqueness, and (2) continuity between
-               # invocations.  However, this will result in a
-               # name that is too long for losing systems, in
-               # some situations.  So we provide _SHORTNAME to
-               # override.
-               my $dname = $derived;
+                 # We choose the name 'DERIVED_OBJECT' to ensure (1) uniqueness,
+                 # and (2) continuity between invocations.  However, this will
+                 # result in a name that is too long for losing systems, in some
 -                # situations.  So we attempt to shorten automatically under
 -                # subdir-objects, and provide _SHORTNAME to override as a last
 -                # resort.  If subdir-object is in effect, it's usually
 -                # unnecessary to use the complete 'DERIVED_OBJECT' (that is
 -                # often the result from %canon_reldir%/%C% usage) since objects
 -                # are placed next to their source file.  Generally, this means
 -                # it is already unique within that directory (see below for an
 -                # exception).  Thus, we try to avoid unnecessarily long file
 -                # names by stripping the directory components of
 -                # 'DERIVED_OBJECT'.  This allows avoiding explicit _SHORTNAME
 -                # usage in many cases.  EXCEPTION: If two (or more) targets in
 -                # different directories but with the same base name (after
 -                # canonicalization), using target-specific FLAGS, link the same
 -                # object, then this logic clashes.  Thus, we don't strip if
 -                # this is detected.
++                # situations.  So we attempt to shorten automatically, and
++                # provide _SHORTNAME to override as a last resort.  If
++                # subdir-object is in effect, it's usually unnecessary to use
++                # the complete 'DERIVED_OBJECT' (that is often the result from
++                # %canon_reldir%/%C% usage) since objects are placed next to
++                # their source file.  Generally, this means it is already
++                # unique within that directory (see below for an exception).
++                # Thus, we try to avoid unnecessarily long file names by
++                # stripping the directory components of 'DERIVED_OBJECT'.
++                # This allows avoiding explicit _SHORTNAME usage in many
++                # cases.  EXCEPTION: If two (or more) targets in different
++                # directories but with the same base name (after
++                # canonicalization), using target-specific FLAGS, link the
++                # same object, then this logic clashes.  Thus, we don't strip
++                # if this is detected.
+                 my $dname = $derived;
+                 if ($directory ne ''
 -                    && option 'subdir-objects'
 -                    && none { $dname =~ /$_$/ } @dup_shortnames)
++                  && none { $dname =~ /$_$/ } @dup_shortnames)
+                   {
+                     # At this point, we don't clear information about what
+                     # parts of $derived are truly file name components.  We can
+                     # determine that by comparing against the canonicalization
+                     # of $directory.
+                     my $dir = $directory . "/";
+                     my $cdir = canonicalize ($dir);
+                     my $dir_len = length ($dir);
+                     # Make sure we only strip full file name components.  This
+                     # is done by repeatedly trying to find cdir at the
+                     # beginning.  Each iteration removes one file name
+                     # component from the end of cdir.
+                     while ($dir_len > 0 && index ($derived, $cdir) != 0)
+                       {
+                         # Eventually $dir_len becomes 0.
+                         $dir_len = rindex ($dir, "/", $dir_len - 2) + 1;
+                         $cdir = substr ($cdir, 0, $dir_len);
+                       }
+                     $dname = substr ($derived, $dir_len);
+                   }
                my $var = var ($derived . '_SHORTNAME');
                if ($var)
                {
@@@ -2142,21 -2343,29 +2242,20 @@@ sub handle_LIBOBJS_or_ALLOC
    # to define LIBOBJDIR and ensure the files get cleaned.
    # Otherwise LIBOBJDIR can be left undefined, and the cleaning
    # is achieved by 'rm -f *.$(OBJEXT)' in compile.am.
 -  if ($config_libobj_dir
 -      && $relative_dir ne $config_libobj_dir)
 -    {
 -      if (option 'subdir-objects')
 -      {
 -        # In the top-level Makefile we do not use $(top_builddir), because
 -        # we are already there, and since the targets are built without
 -        # a $(top_builddir), it helps BSD Make to match them with
 -        # dependencies.
 -        $dir = "$config_libobj_dir/"
 -          if $config_libobj_dir ne '.';
 -        $dir = backname ($relative_dir) . "/$dir"
 -          if $relative_dir ne '.';
 -        define_variable ('LIBOBJDIR', "$dir", INTERNAL);
 -        $clean_files{"\$($var)"} = MOSTLY_CLEAN;
 -        # libtool might create LIBOBJS as a side-effect of using LTLIBOBJS.
 -        $clean_files{"\$(LIBOBJS)"} = MOSTLY_CLEAN if $var eq "LTLIBOBJS";
 -      }
 -      else
 -      {
 -        error ("'\$($var)' cannot be used outside '$config_libobj_dir' if"
 -               . " 'subdir-objects' is not set");
 -      }
 +  if ($config_libobj_dir && $relative_dir ne $config_libobj_dir)
 +    {
 +      # In the top-level Makefile we do not use $(top_builddir), because
 +      # we are already there, and since the targets are built without
 +      # a $(top_builddir), it helps BSD Make to match them with
 +      # dependencies.
 +      $dir = "$config_libobj_dir/"
 +        if $config_libobj_dir ne '.';
 +      $dir = backname ($relative_dir) . "/$dir"
 +        if $relative_dir ne '.';
 +      define_variable ('LIBOBJDIR', "$dir", INTERNAL);
 +      $clean_files{"\$($var)"} = MOSTLY_CLEAN;
-       # If LTLIBOBJS is used, we must also clear LIBOBJS (which might
-       # be created by libtool as a side-effect of creating LTLIBOBJS).
-       $clean_files{"\$($var)"} = MOSTLY_CLEAN if $var =~ s/^LT//;
++      # libtool might create LIBOBJS as a side-effect of using LTLIBOBJS.
++      $clean_files{"\$(LIBOBJS)"} = MOSTLY_CLEAN if $var eq "LTLIBOBJS";
      }
  
    return $dir;
diff --cc bootstrap
index 82ed9937b43b6af8967828d553f7605e74e5b519,82f3859a221324214829ba53c1e6da1504454b57..953577b05240fa500a326413a1262ceef64398ef
+++ b/bootstrap
@@@ -45,10 -44,15 +44,6 @@@ datadir=
  # rule of our Makefile.
  RELEASE_YEAR=2017
  
- # Read the rule for calculating APIVERSION and execute it.
- apiver_cmd=`sed -ne 's/\[\[/[/g;s/\]\]/]/g;/^APIVERSION=/p' configure.ac`
- eval "$apiver_cmd"
 -# Override SHELL.  This is required on DJGPP so that Perl's system()
 -# uses bash, not COMMAND.COM which doesn't quote arguments properly.
 -# It's not used otherwise.
 -if test -n "$DJDIR"; then
 -  BOOTSTRAP_SHELL=/dev/env/DJDIR/bin/bash.exe
 -else
 -  BOOTSTRAP_SHELL=/bin/sh
 -fi
--
  # Sanity checks.
  if test -z "$VERSION"; then
    echo "$me: cannot find VERSION" >&2
diff --cc configure.ac
index 5055780d1677a07dcba8b7ffd12f7537bab32fb5,806dcce4348995a777dc0856424cae04847c8e24..b10faa0b10fb74468b4787938be629476b4ae4e3
@@@ -49,12 -49,7 +49,7 @@@ AC_SUBST([RELEASE_YEAR]
  
  # The API version is the base version.  We must guarantee
  # compatibility for all releases with the same API version.
- # Our current rule is that:
- # * All releases, including the prereleases, in an X.Y series
- #   are compatible.  So 1.5.1c is compatible with 1.5.
- # * Prereleases on the trunk are all incompatible -- 1.5b and 1.5c
- #   aren't the same.
- APIVERSION=`echo "$VERSION" | sed -e 's/^\([[0-9]]*\.[[0-9]]*[[a-z]]*\).*$/\1/'`
 -APIVERSION=1.15a
++APIVERSION=1.99a
  AC_SUBST([APIVERSION])
  
  AC_SUBST([pkgvdatadir], ["\${datadir}/$PACKAGE-$APIVERSION"])
Simple merge
Simple merge
diff --cc lib/texinfo.tex
index 371f60e45e9e51116a3ed467dc00f1f26a0471be,b40a6e2a2bed10a4532c4425e764daa36e3b9f42..513e09b57011a9d52d60b8358557c8f3a7305147
@@@ -3,7 -3,7 +3,7 @@@
  % Load plain if necessary, i.e., if running under initex.
  \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
  %
- \def\texinfoversion{2017-06-16.23}
 -\def\texinfoversion{2017-06-04.19}
++\def\texinfoversion{2017-08-31.18}
  %
  % Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
  % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
diff --cc m4/local.mk
Simple merge
index 35311a117d67d256c4e6af57579972f01b8b2846,07a12ab6f9f2eb43622abfd4ba62497e153f258d..699203ad872585a3b7ec0c2a2041c70472b41cdc
@@@ -102,11 -103,18 +103,18 @@@ sc_sanity_gnu_grep
  .PHONY: sc_sanity_gnu_grep
  $(syntax_check_rules): sc_sanity_gnu_grep
  
+ # Check that every subroutine in perl scripts has a corresponding
+ # prototype
+ sc_perl_protos:
+       $(AM_V_GEN)$(srcdir)/maintainer/check-perl-protos \
+         <$(srcdir)/bin/aclocal.in && \
+       $(srcdir)/maintainer/check-perl-protos <$(srcdir)/bin/automake.in
  # These check avoids accidental configure substitutions in the source.
 -# There are exactly 8 lines that should be modified from automake.in to
 +# There are exactly 7 lines that should be modified from automake.in to
  # automake, and 9 lines that should be modified from aclocal.in to
  # aclocal.
 -automake_diff_no = 8
 +automake_diff_no = 7
  aclocal_diff_no = 9
  sc_diff_automake sc_diff_aclocal: in=$($*_in)
  sc_diff_automake sc_diff_aclocal: out=$($*_script)
Simple merge