]> sourceware.org Git - automake.git/commitdiff
* automake.in (initialize_per_input): Initialize %directory_map.
authorTom Tromey <tromey@redhat.com>
Sun, 11 Apr 1999 11:24:14 +0000 (11:24 +0000)
committerTom Tromey <tromey@redhat.com>
Sun, 11 Apr 1999 11:24:14 +0000 (11:24 +0000)
(handle_single_transform_list): Only create .dirstamp rules once
per directory.

ChangeLog
automake.in

index 3edb42af4fa62c93c007e4f2bfb2075df5c52a54..37ad6fc6b903d850072c1c85108b781d0b14feca 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 1999-04-11  Tom Tromey  <tromey@cygnus.com>
 
+       * automake.in (initialize_per_input): Initialize %directory_map.
+       (handle_single_transform_list): Only create .dirstamp rules once
+       per directory.
+
        * m4/gcj.m4 (AM_PROG_GCJ): Use AC_CHECK_PROGS, not AC_CHECK_PROG.
 
        Fix for confh.test:
index 37a0a4dd7e9b3c1669fe5bee6654acdeaacf8e37..d48370bbf2bd842cf3e2070cb7b33d0a72c057e6 100755 (executable)
@@ -1169,21 +1169,26 @@ sub handle_single_transform_list
                        &am_error ("\`$full' contains \`..' component but should not");
                    }
 
-                   push (@dep_list, $directory . '/.dirstamp');
-                   $output_rules .= ($directory . "/.dirstamp:\n"
-                                     . "\t\@\$(mkinstalldirs) $directory\n"
-                                     . "\t\@: > $directory/.dirstamp\n");
-
-                   # If we're generating dependencies, we also want
-                   # to make sure that the appropriate subdir of the
-                   # .deps directory is created.
-                   if ($use_dependencies)
+                   if (! defined $directory_map{$directory})
                    {
-                       push (@dep_list, '.deps/' . $directory . '/.dirstamp');
-                       $output_rules .= ('.deps/' . $directory
-                                         . "/.dirstamp:\n"
-                                         . "\t\@\$(mkinstalldirs) .deps/$directory\n"
-                                         . "\t\@: > .deps/$directory/.dirstamp\n");
+                       $directory_map{$directory} = 1;
+
+                       push (@dep_list, $directory . '/.dirstamp');
+                       $output_rules .= ($directory . "/.dirstamp:\n"
+                                         . "\t\@\$(mkinstalldirs) $directory\n"
+                                         . "\t\@: > $directory/.dirstamp\n");
+
+                       # If we're generating dependencies, we also
+                       # want to make sure that the appropriate
+                       # subdir of the .deps directory is created.
+                       if ($use_dependencies)
+                       {
+                           push (@dep_list, '.deps/' . $directory . '/.dirstamp');
+                           $output_rules .= ('.deps/' . $directory
+                                             . "/.dirstamp:\n"
+                                             . "\t\@\$(mkinstalldirs) .deps/$directory\n"
+                                             . "\t\@: > .deps/$directory/.dirstamp\n");
+                       }
                    }
                }
 
@@ -6619,6 +6624,10 @@ sub initialize_per_input
     # by a single source file.
     %object_map = ();
 
+    # This keeps track of the directories for which we've already
+    # created `.dirstamp' code.
+    %directory_map = ();
+
     # These variables track inclusion of various compile-related .am
     # files.  $included_generic_compile is TRUE if the basic code has
     # been included.  $included_knr_compile is TRUE if the ansi2knr
This page took 0.044376 seconds and 5 git commands to generate.