From ee31c619dbd24452463a426baf4eab9ea3a5bd54 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Fri, 15 Nov 1996 06:54:00 +0000 Subject: [PATCH] Bug fixes --- ChangeLog | 20 ++++++++++++++++++++ NEWS | 2 +- README | 6 +++--- README-alpha | 17 ++--------------- TODO | 11 +++++++++-- automake.in | 36 +++++++++++++++++------------------- automake.texi | 2 +- configure | 2 +- configure.in | 2 +- dejagnu.am | 8 +++++++- depend2.am | 5 +++-- lib/am/dejagnu.am | 8 +++++++- lib/am/depend2.am | 5 +++-- version.texi | 6 +++--- 14 files changed, 78 insertions(+), 52 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7ec4eda..1620d39 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,25 @@ +Thu Nov 14 23:11:09 1996 Tom Tromey + + * automake.in (handle_yacc_lex_cxx): Don't auto-define YACC, LEX, + CXX, CC. + + * dejagnu.am: Print warning if runtest missing. + + From Joerg-Martin Schwarz: + * automake.in (handle_aclocal_m4): Find aclocal.m4 in srcdir. + (require_file_internal): Unlink file before creating it. + + * depend2.am (.deps/%.P): Don't print commands when running. + +Mon Nov 11 10:35:08 1996 Tom Tromey + + * automake.in (handle_single_transform_list): Simplified C++ + matching expression. + Fri Nov 8 09:49:09 1996 Tom Tromey + * Released 1.1g. + * compile-kr.am ($(OBJECTS)): Removed. * automake.in (get_object_extension): Define ANSI2KNR. Push onto diff --git a/NEWS b/NEWS index e5dbf0d..f362eb4 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,4 @@ -New in 1.1g: +New in 1.1h: * Bug fixes * Better DejaGNU support * Added no-installinfo option diff --git a/README b/README index 8df99c8..d28ac7c 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ -This is Automake, an experimental Makefile generator. It was inspired -by the 4.4BSD make and include files, but aims to be portable and to -conform to the GNU standards for Makefile variables and targets. +This is Automake, a Makefile generator. It was inspired by the 4.4BSD +make and include files, but aims to be portable and to conform to the +GNU standards for Makefile variables and targets. Automake is a Perl script. The input files are called Makefile.am. The output files are called Makefile.in; they are intended for use diff --git a/README-alpha b/README-alpha index 424f0a3..61b8d33 100644 --- a/README-alpha +++ b/README-alpha @@ -4,26 +4,13 @@ GNU mailing list or newsgroup. A few notes on this particular release: -* If upgrading from a previous test release, you must remove all the - old installed m4 files; their names have changed to fit into the 14 - char limit. These files are ordinarily in $(prefix)/share/aclocal. - -* The `missing' program is still not in use, pending +* The `missing' program is still not in use. * The `acinstall' program is distributed but not used; I still must write the internal support for it. This is the program that will be used to install macro files for aclocal. -* The documentation needs more work. For instance the macros that - come with aclocal are not fully documented. - -* Right now the generated Makefiles will print the commands used for - (eg) installing, no matter how ugly. These commands give no - feedback as they do their work. It has been suggested that these - command be made invisible (using "@"), and also print something as - they work (eg "installing foo as /a/b/foo"). I'd appreciate - feedback on this idea, especially if you have particular reasons for - preferring one over the other. +* The documentation needs a lot more work. Please send comments and problem reports about this test release to tromey@cygnus.com -- ignore the bug reporting addresses given by the diff --git a/TODO b/TODO index 1cef398..e990a3c 100644 --- a/TODO +++ b/TODO @@ -5,6 +5,8 @@ Priorities for release: * `missing' program * copyrights on m4 files, aclocal output +* clean up source directory by moving stuff into subdirs + !! foo_LIBRARIES = @JOE@ -> _LIBFILES is wrong [ have implemented temporary fix, but something better must be done probably do Gord's idea ] @@ -172,6 +174,10 @@ Things to finish libtool support: * Handle clean changes * New definition for LINK +DJM wants ``LINKS'' variable; list of things to link together after +install. In BSD environment, use: + LINKS = from1 to1 from2 to2 ... + Need way to say there are no suffixes in a Makefile (Franc,ois' "override" idea suffices here) @@ -230,6 +236,7 @@ Lex, yacc support: * Consider supporting syntax from autoconf "derived:source", eg: y.tab.c:perly.y for yacc and lex source +* allow generating c++ source from lex? Eg using flex? Multi-language support: * should have mapping of file extensions to languages @@ -321,11 +328,11 @@ OMIT_DEPENDENCIES write example of using automake with dejagnu follow calc example in dejagnu docs -document gdb's yacc hack for including multiple parsers - document which variables are actually scanned and which are not. finish yacc, lex + need for LEXLIB + document gdb's yacc hack for including multiple parsers Document customary ordering of Makefile.am. From François. diff --git a/automake.in b/automake.in index 9200e96..a380a09 100755 --- a/automake.in +++ b/automake.in @@ -24,7 +24,7 @@ eval 'exec @PERL@ -S $0 ${1+"$@"}' # 02111-1307, USA. # Originally written by David Mackenzie . -# Perl reimplementation by Tom Tromey . +# Perl reimplementation by Tom Tromey . # Parameters set by configure. Not to be changed. NOTE: assign @@ -678,7 +678,6 @@ sub handle_yacc_lex_cxx if ($yacc_count) { push (@suffixes, '.y'); - &define_configure_variable ('YACC'); $output_rules .= ".y.c:\n\t"; if ($yacc_count > 1) { @@ -693,14 +692,12 @@ sub handle_yacc_lex_cxx if (! defined $configure_vars{'YACC'}) { - # FIXME: should include a reference line. - &am_error ("yacc source seen but \`YACC' not defined in \`configure.in'\n"); + &am_error ("yacc source seen but \`YACC' not defined in \`configure.in'"); } } if ($lex_count) { push (@suffixes, '.l'); - &define_configure_variable ('LEX'); &define_configure_variable ('LEX_OUTPUT_ROOT'); &define_configure_variable ('LEXLIB'); $output_rules .= ".l.c:\n\t"; @@ -716,11 +713,11 @@ sub handle_yacc_lex_cxx if (! defined $configure_vars{'LEX'}) { - &am_error ("lex source seen but \`LEX' not defined in \`configure.in'\n"); + &am_error ("lex source seen but \`LEX' not defined in \`configure.in'"); } if (! $seen_decl_yytext) { - &am_error ("lex source seen but \`AC_DECL_YYTEXT' not in \`configure.in'\n"); + &am_error ("lex source seen but \`AC_DECL_YYTEXT' not in \`configure.in'"); } } @@ -744,7 +741,6 @@ sub handle_yacc_lex_cxx { push (@suffixes, @cxx_list); - &define_configure_variable ("CXX"); &define_configure_variable ("CXXFLAGS"); &define_variable ('CXXCOMPILE', '$(CXX) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CXXFLAGS)'); &define_variable ('CXXLINK', '$(CXX) $(LDFLAGS) -o $@'); @@ -758,7 +754,7 @@ sub handle_yacc_lex_cxx if (! defined $configure_vars{'CXX'}) { - &am_error ("C++ source seen but \`CXX' not defined in \`configure.in'\n"); + &am_error ("C++ source seen but \`CXX' not defined in \`configure.in'"); } } @@ -767,11 +763,15 @@ sub handle_yacc_lex_cxx # if ($seen_c_source) { - &define_configure_variable ('CC'); &define_configure_variable ('CFLAGS'); &define_variable ('COMPILE', '$(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)'); &define_variable ('LINK', '$(CC) $(LDFLAGS) -o $@'); + + if (! defined $configure_vars{'CC'}) + { + &am_error + ("C source seen but \`CC' not defined in \`configure.in'"); } } @@ -854,13 +854,9 @@ sub handle_single_transform_list # Transform source files into .o files. List of C++ # extensions comes from Emacs 19.32 etags. - if (s/\.c\+\+$/.o/g - || s/\.cc$/.o/g - || s/\.cpp$/.o/g - || s/\.cxx$/.o/g - || s/\.C$/.o/g) + if (s/\.(c\+\+|cc|cpp|cxx|C)$/o/) { - $cxx_extensions{$&} = 1; + $cxx_extensions{'.' . $1} = 1; $linker = 'CXXLINK'; } else @@ -2210,7 +2206,7 @@ sub handle_aclocal_m4 # important. if ($regen_aclocal) { - $output_rules .= ("aclocal.m4: " + $output_rules .= ("\$(srcdir)/aclocal.m4: " . ($seen_maint_mode ? "\@MAINT\@" : "") . "configure.in" . ($acinclude ? ' acinclude.m4' : '') @@ -4251,8 +4247,10 @@ sub require_file_internal { $trailer = "; installing"; $suppress = 1; - # Install the missing file. Symlink if we can, copy - # if we must. + # Install the missing file. Symlink if we can, + # copy if we must. Note: delete the file first, + # in case it is a dangling symlink. + unlink ($errfile); if ($symlink_exists) { if (! symlink ($am_dir . '/' . $file, $errfile)) diff --git a/automake.texi b/automake.texi index a4787e1..97fc420 100644 --- a/automake.texi +++ b/automake.texi @@ -65,7 +65,7 @@ This is the first edition of the GNU Automake documentation,@* and is consistent with GNU Automake @value{VERSION}.@* @sp 2 Published by the Free Software Foundation @* -59 Template Place - Suite 330, @* +59 Temple Place - Suite 330, @* Boston, MA 02111-1307 USA @* Permission is granted to make and distribute verbatim copies of diff --git a/configure b/configure index 7717786..f582014 100755 --- a/configure +++ b/configure @@ -601,7 +601,7 @@ cat >> confdefs.h <> confdefs.h < /dev/null 2>&1; then \ + $$runtest --tool $(DEJATOOL) --srcdir $$srcdir $(RUNTESTFLAGS); \ + else echo "WARNING: could not find \`runtest'" 1>&2; :;\ + fi diff --git a/depend2.am b/depend2.am index a0c31bb..dfe0d85 100644 --- a/depend2.am +++ b/depend2.am @@ -16,9 +16,10 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. .deps/%.P: $(srcdir)/%@EXT@ - $(@MKDEP@) $< > $@-tmp + @echo "Computing dependencies for $<..." + @$(@MKDEP@) $< > $@-tmp ## FIXME: shouldn't do this for languages other than C. - if test -n "$o"; then \ + @if test -n "$o"; then \ sed 's/\.o:/$$o:/' $@-tmp > $@; \ rm $@-tmp; \ else \ diff --git a/lib/am/dejagnu.am b/lib/am/dejagnu.am index dbb54bf..f8a7ad6 100644 --- a/lib/am/dejagnu.am +++ b/lib/am/dejagnu.am @@ -32,4 +32,10 @@ CYGNUS if [ -f $(top_builddir)/../expect/expect ]; then \ CYGNUS TCL_LIBRARY=`cd $(top_srcdir)/../tcl/library && pwd`; \ CYGNUS export TCL_LIBRARY; \ CYGNUS fi; \ - $(RUNTEST) --tool $(DEJATOOL) --srcdir $$srcdir $(RUNTESTFLAGS) + runtest=$(RUNTEST); \ +## If runtest can't be found, print a warning but don't die. It is +## pointless to cause a failure if the tests cannot be run at all. + if $(SHELL) -c "$$runtest --version" > /dev/null 2>&1; then \ + $$runtest --tool $(DEJATOOL) --srcdir $$srcdir $(RUNTESTFLAGS); \ + else echo "WARNING: could not find \`runtest'" 1>&2; :;\ + fi diff --git a/lib/am/depend2.am b/lib/am/depend2.am index a0c31bb..dfe0d85 100644 --- a/lib/am/depend2.am +++ b/lib/am/depend2.am @@ -16,9 +16,10 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. .deps/%.P: $(srcdir)/%@EXT@ - $(@MKDEP@) $< > $@-tmp + @echo "Computing dependencies for $<..." + @$(@MKDEP@) $< > $@-tmp ## FIXME: shouldn't do this for languages other than C. - if test -n "$o"; then \ + @if test -n "$o"; then \ sed 's/\.o:/$$o:/' $@-tmp > $@; \ rm $@-tmp; \ else \ diff --git a/version.texi b/version.texi index e857925..b9c052e 100644 --- a/version.texi +++ b/version.texi @@ -1,3 +1,3 @@ -@set UPDATED 20 October 1996 -@set EDITION 1.1g -@set VERSION 1.1g +@set UPDATED 14 November 1996 +@set EDITION 1.1h +@set VERSION 1.1h -- 2.7.4