diff -ur automake-1.2/automake.in automake-1.2.1/automake.in --- automake-1.2/automake.in Sun Jun 22 21:47:56 1997 +++ automake-1.2.1/automake.in Mon Jun 30 19:31:59 1997 @@ -610,6 +610,7 @@ { return 0 if ! &variable_defined ('AUTOMAKE_OPTIONS'); + $use_distdir = '$(PACKAGE)-$(VERSION)'; foreach (&variable_value_as_list ('AUTOMAKE_OPTIONS', '')) { $options{$_} = 1; @@ -635,6 +636,10 @@ { $use_dependencies = 0; } + elsif (/distdir=(\S+)/) + { + $use_distdir = "$1"; + } elsif (/([0-9]+)\.([0-9]+)/) { # Got a version number. Note that alpha releases count as @@ -920,8 +921,10 @@ local ($base, @objects); foreach $base (sort (keys %de_ansi_files)) { - $output_rules .= $base . "_.c: $base.c\n\t" - . '$(ANSI2KNR) $< ' . $base . "_.c\n"; + # Each _.c file must depend on ansi2knr; otherwise it + # might be used in a parallel build before it is built. + $output_rules .= $base . "_.c: $base.c \$(ANSI2KNR)\n\t" + . '$(ANSI2KNR) ' . $base . '.c ' . $base . "_.c\n"; push (@objects, $base . '_.o'); push (@objects, $base . '_.lo') if $seen_libtool; } @@ -2467,7 +2472,7 @@ { if ($relative_dir eq '.') { - $output_rules .= "\n" . 'distdir = $(PACKAGE)-$(VERSION)' . "\n"; + $output_rules .= "\n" . 'distdir = ' . $use_distdir . "\n"; } else {