From: Tom Tromey Date: Mon, 1 Dec 1997 20:54:33 +0000 (+0000) Subject: fixed objc.test bug X-Git-Tag: pre-depend-change~19 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=4f909a99549e12b6e999b8d0dcd31cd47c7e11ce;p=automake.git fixed objc.test bug --- diff --git a/ChangeLog b/ChangeLog index 54a82854..70255cdf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Mon Dec 1 13:52:39 1997 Tom Tromey + + Fixes for test objc.test: + * automake.in (initialize_per_input): New global seen_any_source. + (handle_yacc_lex_cxx): Use seen_any_source to decide when to + define LINK, et al. + (handle_single_transform_list): Set seen_any_source. + (handle_lib_objects_cond): Likewise. + Wed Nov 26 13:41:57 1997 Tom Tromey * Released 1.2d. diff --git a/README b/README index 1397bdc3..634a0f86 100644 --- a/README +++ b/README @@ -19,9 +19,9 @@ program to generate an `aclocal.m4' based on the contents of for augmenting autoconf. It is intended that other package authors will write m4 macros which can be automatically used by aclocal. -The mailing list automake@gnu.ai.mit.edu is for discussion of +The mailing list automake@gnu.org is for discussion of Automake, Autoconf, and other configuration/portability tools (e.g., -libtool). Write to automake-request@gnu.ai.mit.edu if you want to +libtool). Write to automake-request@gnu.org if you want to join. -Mail suggestions and bug reports to automake-bugs@gnu.ai.mit.edu. +Mail suggestions and bug reports to automake-bugs@gnu.org. diff --git a/automake.in b/automake.in index 5aeacdf4..2f673f4f 100755 --- a/automake.in +++ b/automake.in @@ -962,7 +962,7 @@ sub handle_yacc_lex_cxx # # Last, handle some C cleanup. # - if ($seen_c_source) + if ($seen_any_source) { &define_configure_variable ('CFLAGS'); &define_variable ('COMPILE', @@ -972,12 +972,12 @@ sub handle_yacc_lex_cxx '$(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)') if ($seen_libtool); &define_variable ('LINK', $ltlink . '$(CC) $(CFLAGS) $(LDFLAGS) -o $@'); + } - if (! defined $configure_vars{'CC'}) - { - &am_line_error ($seen_c_source, - "C source seen but \`CC' not defined in \`configure.in'"); - } + if ($seen_c_source && ! defined $configure_vars{'CC'}) + { + &am_line_error ($seen_c_source, + "C source seen but \`CC' not defined in \`configure.in'"); } } @@ -1186,6 +1186,7 @@ sub handle_single_transform_list next; } + $seen_any_source = 1; push (@result, $_); # Transform .o or $o file into .P file (for automatic @@ -1394,6 +1395,7 @@ sub handle_lib_objects_cond if ($iter =~ /\.[cly]$/) { $seen_c_source = $var; + $seen_any_source = 1; } if ($iter =~ /\.h$/) @@ -1417,6 +1419,7 @@ sub handle_lib_objects_cond $dep_files{'.deps/alloca.P'} = 1; &require_file_with_line ($var, $FOREIGN, 'alloca.c'); $seen_c_source = $var; + $seen_any_source = 1; } } @@ -5470,6 +5473,9 @@ sub initialize_per_input # mentioned the sources. $seen_c_source = 0; + # TRUE if we've seen any sources at all. + $seen_any_source = 0; + # This is a list of all targets to run during "make dist". @dist_targets = ();