From 71a3c91565cb04e265309bf67f4f69fa05cdb94a Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sat, 24 Aug 1996 23:52:08 +0000 Subject: [PATCH] Fixlets --- ChangeLog | 14 ++++++ TODO | 34 -------------- automake.in | 29 ++++++++++-- automake.texi | 99 +++++++++++++++++++++++++++++++++++++--- m4/AM_MAINTAINER_MODE.m4 | 3 ++ version.texi | 2 +- 6 files changed, 135 insertions(+), 46 deletions(-) diff --git a/ChangeLog b/ChangeLog index ba7105ef..14a34190 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,19 @@ Sat Aug 24 09:30:46 1996 Tom Tromey + Reported by Jim Meyering: + * automake.in (get_object_extension): Look in "./" for ansi2knr if + no path found. + (handle_aclocal_m4): Protect aclocal.m4 rule with @MAINT@. + + * remake.am (.PHONY): New target. + + * m4/AM_MAINTAINER_MODE.m4: Also define UNMAINT. + + * automake.in (check_gnu_standards): Disallow no-installman, + no-installinfo. + (read_am_file): Sed out UNMAINT too. + (file_contents_with_transform): Ditto. + * acinstall: New file. * m4/AM_INIT_AUTOMAKE.m4: Define PACKAGE and VERSION. diff --git a/TODO b/TODO index b0bf9631..25b2bf82 100644 --- a/TODO +++ b/TODO @@ -9,9 +9,6 @@ Priorities for release: should put inverse of @MAINT@ before `.PHONY: configure' -* some options must be turned off when --gnu or higher - eg no-installinfo - * must update GNU Hello ** when can aclocal.m4 be auto-generated? @@ -289,23 +286,6 @@ autosystem... Document: - -Defined variables, their meanings, and their effects: - -DEFS cpp definitions -INCLUDES -I options to cpp -CPPFLAGS more cpp flags -CFLAGS flags to cc -COMPILE how to compile a C program -LINK how to link a C program - -DIST_SUBDIRS directories which are copied verbatim into the - distribution. Used eg for directories holding - only example code (which don't have their own - makefile). This variable might be a bad idea. - [ should just require a new Makefile.am. They are supposed to be - easy to write ] - Document customary ordering of Makefile.am. From François. must document that @ALLOCA@ works in _LDADD @@ -315,9 +295,6 @@ Must document BUILT_SOURCES variable. See depend.am. Should include extended version of diagram from Autoconf (suggested by Greg Woods) -Must document macros which can be used when writing one's own rules. -Must document INCLUDES - Document gettext support Make a definition of the term "source" @@ -327,16 +304,10 @@ need xref to libtool in docs document how to use Automake with CVS. Idea from Mark Galassi. Also include Greg Woods' more sophisticated "cvs-dist" target. -document that there is no uninstall-{exec,data} - document rebuilding configure. CONFIGURE_DEPENDENCIES -document TAGS_DEPENDENCIES - document new variables introduced when AC_CANONICAL_* used -document _LISP handling - document canonicalization for texinfos automake must be run in each directory with a configure.in @@ -347,11 +318,6 @@ non-automake-using subdirs document actual uses of PACKAGE and VERSION -> Oh, ok. This should be documented: make the last argument of your -> AC_OUTPUT line look like this: -> -> test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h - Must document aclocal program djm says: diff --git a/automake.in b/automake.in index 6cf193c0..a5421385 100755 --- a/automake.in +++ b/automake.in @@ -568,7 +568,13 @@ sub get_object_extension } $output_vars .= "o = .\@U\@o\n"; - $output_vars .= "ANSI2KNR = " . $options{'ansi2knr'} . "\n"; + + # Make sure ansi2knr can be found: if no path specified, + # specify "./". + local ($apath) = $options{'ansi2knr'}; + $apath = './' . $apath + unless $apath =~ /\//; + $output_vars .= "ANSI2KNR = " . $apath . "\n"; $output_rules .= &file_contents ('compile-kr'); $output_rules .= &file_contents ('clean-kr'); @@ -1765,7 +1771,7 @@ sub handle_aclocal_m4 if ($regen_aclocal) { - $output_rules .= ("aclocal.m4: configure.in" + $output_rules .= ("aclocal.m4: \@MAINT\@configure.in" . ($acinclude ? ' acinclude.m4' : '') . "\n\t" . 'cd $(srcdir) && aclocal' @@ -2638,6 +2644,21 @@ sub check_gnu_standards &require_file ($GNU, 'INSTALL', 'NEWS', 'README', 'COPYING', 'AUTHORS', 'ChangeLog'); } + + if ($strictness >= $GNU) + { + if (defined $options{'no-installman'}) + { + &am_line_error ('AUTOMAKE_OPTIONS', + "option \`no-installman' disallowed by GNU standards"); + } + + if (defined $options{'no-installinfo'}) + { + &am_line_error ('AUTOMAKE_OPTIONS', + "option \`no-installinfo' disallowed by GNU standards"); + } + } } # Do any extra checking for GNITS standards. @@ -2819,7 +2840,7 @@ sub read_am_file $_ .= "\n" unless substr ($_, -1, 1) eq "\n"; - $_ =~ s/\@MAINT\@//g + $_ =~ s/\@(UN)?MAINT\@//g unless $seen_maint_mode; if (/$IGNORE_PATTERN/o) @@ -3113,7 +3134,7 @@ sub file_contents_with_transform while () { - $_ =~ s/\@MAINT\@//g + $_ =~ s/\@UNMAINT\@//g unless $seen_maint_mode; eval $command; diff --git a/automake.texi b/automake.texi index 52bcdebf..91d28d47 100644 --- a/automake.texi +++ b/automake.texi @@ -105,6 +105,7 @@ documents version @value{VERSION}. * Top level:: The top-level Makefile.am * Programs:: Building programs and libraries * Other objects:: Other derived objects +* Emacs Lisp:: Emacs Lisp support * Documentation:: Building documentation * Install:: What gets installed * Clean:: What gets cleaned @@ -436,7 +437,8 @@ header. If you do use this macro, you must create the file @file{stamp-h.in}. It can be empty. Also, the @code{AC_OUTPUT} command in @file{configure.in} must create @file{stamp-h}, eg: @example -AC_OUTPUT(Makefile, [test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h]) +AC_OUTPUT(Makefile, +[test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h]) @end example @cvindex AC_CONFIG_HEADER @@ -583,6 +585,9 @@ to build C programs and libraries. @menu * A Program:: Building a program * A Library:: Building a library +* Program variables:: Variables used when building a program +* Yacc and Lex:: Yacc and Lex support +* C++:: C++ and other languages * ANSI:: Automatic de-ANSI-fication * Dependencies:: Automatic dependency tracking @end menu @@ -728,6 +733,40 @@ distribution (@pxref{Dist}). These source files are also automatically handled in the dependency-tracking scheme, see @xref{Dependencies}. +@node Program variables +@section Variables used when building a program + +@table @code +@item CC +@item CFLAGS +@item CPPFLAGS +@item CXX +@item CXXFLAGS +@item DEFS +@item LDFLAGS +@item LIBS + +@item INCLUDES +@item COMPILE +@item LINK +@end table + + +@node Yacc and Lex +@section Yacc and Lex support + +Y + +@node C++ +@section C++ and other languages + +Automake includes full support for C++, and rudimentary support for +other languages. Support for other languages will be improved based on +demand. + + + + @node ANSI @section Automatic de-ANSI-fication @@ -884,6 +923,23 @@ dependency tracking is done. Built sources are included in a distribution. +@node Emacs Lisp +@chapter Emacs Lisp + +Automake provides some support for Emacs Lisp. The @samp{LISP} primary +is used to hold a list of @samp{.el} files. Possible prefixes for this +primary are @samp{lisp_} and @samp{noinst_}. Note that if +@code{lisp_LISP} is defined, then @file{configure.in} must run +@code{AM_PATH_LISPDIR} (fixme xref). +@vindex LISP +@vindex lisp_LISP +@vindex noinst_LISP + +By default Automake will byte-compile all Emacs Lisp source files using +the Emacs found by @code{AM_PATH_LISPDIR}. If you wish to avoid +byte-compiling, simply define the variable @samp{ELCFILES} to be empty. +@vindex ELCFILES + @node Documentation @chapter Building documentation @@ -1118,29 +1174,50 @@ The same as the corresponding @samp{--strictness} option. @item @code{no-installman} The generated @file{Makefile.in} will not cause man pages to be installed by default. However, an @code{install-man} target will still -be available for optional installation. +be available for optional installation. This option is disallowed at +@samp{GNU} strictness and above. @trindex install-man @item @code{no-installinfo} The generated @file{Makefile.in} will not cause info pages to be built or installed by default. However, @code{info} and @code{install-info} -targets will still be available. +targets will still be available. This option is disallowed at +@samp{GNU} strictness and above. @trindex info @trindex install-info @item @code{ansi2knr} -Turn on automatic de-ANSI-fication. +@item @code{path/ansi2knr} +Turn on automatic de-ANSI-fication. If preceeded by a path, the +generated @file{Makefile.in} will look in the specified directory to +find the @file{ansi2knr} program. Generally the path should be a +relative path to another directory in the same distribution (though +Automake currently does not check this). It is up to you to make sure +that the specified directory is built before the current directory; if +@file{ansi2knr} does not exist then the build will fail. + +@item @code{dejagnu} +Cause @code{dejagnu}-specific rules to be generated. @xref{Tests}. @item @code{dist-shar} Generate a @code{dist-shar} target as well as the ordinary @code{dist} -target. +target. This new target will create a shar archive of the +distribution. @trindex dist-shar @item @code{dist-zip} Generate a @code{dist-zip} target as well as the ordinary @code{dist} -target. +target. This new target will create a zip archive of the distribution. @trindex dist-zip +@item @code{dist-tarZ} +Generate a @code{dist-tarZ} target as well as the ordinary @code{dist} +target. This new target will create a compressed tar archive of the +distribution; a traditional @code{tar} and @code{compress} will be +assumed. Warning: if you are actually using @code{GNU tar}, then the +generated archive might contain nonportable constructs. +@trindex dist-tarZ + @item @code{no-dependencies} This is similar to using @samp{--include-deps} on the command line, but is useful for those situations where you don't have the necessary bits @@ -1186,6 +1263,7 @@ subdirectories. Also, if the variable @code{ETAGS_ARGS} is defined, a @code{tags} target will be generated. This variable is intended for use in directories which contain taggable source that @code{etags} does not understand. +@vindex ETAGS_ARGS Here is how Automake generates tags for its source, and for nodes in its Texinfo file: @@ -1195,6 +1273,11 @@ ETAGS_ARGS = automake.in --lang=none \ --regex='/^@@node[ \t]+\([^,]+\)/\1/' automake.texi @end example +If you add filenames to @var{ETAGS_ARGS}, you will probably also +want to set @var{TAGS_DEPENDENCIES}. The contents of this variable +are added directly to the dependencies for the @code{tags} target. +@vindex TAGS_DEPENDENCIES + Automake will also generate an @code{ID} target which will run @code{mkid} on the source. This is only supported on a directory-by-directory basis. @@ -1236,7 +1319,9 @@ these user-supplied targets. The targets that support a local version are @code{all}, @code{info}, @code{dvi}, @code{check}, @code{install-data}, @code{install-exec}, and -@code{uninstall}. +@code{uninstall}. Note that there are no @code{uninstall-exec-local} or +@code{uninstall-data-local} targets; just use @code{uninstall-local}. +It doesn't make sense to uninstall just data or just executables. @trindex all @trindex info @trindex dvi diff --git a/m4/AM_MAINTAINER_MODE.m4 b/m4/AM_MAINTAINER_MODE.m4 index 5d9a7658..f4425121 100644 --- a/m4/AM_MAINTAINER_MODE.m4 +++ b/m4/AM_MAINTAINER_MODE.m4 @@ -14,9 +14,12 @@ AC_DEFUN(AM_MAINTAINER_MODE, AC_MSG_RESULT($USE_MAINTAINER_MODE) if test $USE_MAINTAINER_MODE = yes; then MAINT= + UNMAINT='#M#' else MAINT='#M#' + UNMAINT= fi AC_SUBST(MAINT)dnl + AC_SUBST(UNMAINT)dnl ] ) diff --git a/version.texi b/version.texi index 08683df8..8204d929 100644 --- a/version.texi +++ b/version.texi @@ -1,3 +1,3 @@ -@set UPDATED 10 August 1996 +@set UPDATED 24 August 1996 @set EDITION 1.1d @set VERSION 1.1d -- 2.43.5