]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
Merge branch 'minor' next
authorMathieu Lirzin <mthl@gnu.org>
Tue, 19 Sep 2017 11:29:18 +0000 (13:29 +0200)
committerMathieu Lirzin <mthl@gnu.org>
Tue, 19 Sep 2017 11:29:18 +0000 (13:29 +0200)
1  2 
NEWS
bin/automake.in
t/list-of-tests.mk

diff --cc NEWS
Simple merge
diff --cc bin/automake.in
index 4a7bc12038a61d408e797460adc621e03584da65,653340563a40573ee7c066a8f92c79cc9e8c4364..6621302d83f65f16338663eec8190839d3afe5e1
@@@ -2242,20 -2344,38 +2244,29 @@@ 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);
 -        if ($dir && !defined $clean_files{"$dir$base.\$(OBJEXT)"})
 -          {
 -            my $dirstamp = require_build_directory ($dir);
 -            $output_rules .= "$dir$base.\$(OBJEXT): $dirstamp\n";
 -            $output_rules .= "$dir$base.lo: $dirstamp\n"
 -              if ($var =~ /^LT/);
 -          }
 -        # libtool might create .$(OBJEXT) as a side-effect of using
 -        # LTLIBOBJS or LTALLOCA.
 -        $clean_files{"$dir$base.\$(OBJEXT)"} = MOSTLY_CLEAN;
 -        $clean_files{"$dir$base.lo"} = MOSTLY_CLEAN
 +  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;
-       # libtool might create LIBOBJS as a side-effect of using LTLIBOBJS.
-       $clean_files{"\$(LIBOBJS)"} = MOSTLY_CLEAN if $var eq "LTLIBOBJS";
++      if ($dir && !defined $clean_files{"$dir$base.\$(OBJEXT)"})
++      {
++        my $dirstamp = require_build_directory ($dir);
++        $output_rules .= "$dir$base.\$(OBJEXT): $dirstamp\n";
++        $output_rules .= "$dir$base.lo: $dirstamp\n"
+           if ($var =~ /^LT/);
+       }
 -      else
 -      {
 -        error ("'\$($var)' cannot be used outside '$config_libobj_dir' if"
 -               . " 'subdir-objects' is not set");
 -      }
++      # libtool might create .$(OBJEXT) as a side-effect of using
++      # LTLIBOBJS or LTALLOCA.
++      $clean_files{"$dir$base.\$(OBJEXT)"} = MOSTLY_CLEAN;
++      $clean_files{"$dir$base.lo"} = MOSTLY_CLEAN
++      if ($var =~ /^LT/);
      }
  
    return $dir;
Simple merge