From: Tom Tromey Date: Thu, 18 Jan 1996 07:31:23 +0000 (+0000) Subject: Initialize strictness to 'normal' X-Git-Tag: Release-0-29~19 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=08750c0c8d30491757a67344a7a4b1a4d75875d7;p=automake.git Initialize strictness to 'normal' --- diff --git a/ChangeLog b/ChangeLog index 331baf8b..c7db9d0e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,12 @@ +Thu Jan 18 00:25:56 1996 Tom Tromey + + * automake.in (parse_arguments): Initialize strictness to + 'normal'. + Sun Jan 14 13:54:16 1996 Tom Tromey + * automake.in (scan_configure): Look for NLS support. + Changes from François Pinard: * texinfos.am (install-info): Correctly install when build dir is not srcdir. diff --git a/Makefile.am b/Makefile.am index 8ad51a9a..6d2c9188 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,5 @@ +## Process this file with automake to create Makefile.in + AUTOMAKE_OPTIONS = gnits bin_SCRIPTS = automake diff --git a/Makefile.in b/Makefile.in index 295117bb..31d5ca2f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -75,9 +75,9 @@ DVIS = automake.dvi DATA = $(pkgdata_DATA) -DIST_COMMON = README mkinstalldirs configure Makefile.in stamp-vti \ -AUTHORS configure.in ChangeLog THANKS README version.texi mdate-sh TODO \ -INSTALL COPYING Makefile.am texinfo.tex NEWS aclocal.m4 install-sh +DIST_COMMON = README AUTHORS COPYING ChangeLog INSTALL Makefile.am \ +Makefile.in NEWS README THANKS TODO aclocal.m4 configure configure.in \ +install-sh mdate-sh mkinstalldirs stamp-vti texinfo.tex version.texi PACKAGE = @PACKAGE@ @@ -159,7 +159,7 @@ automake.info: automake.texi version.texi install-info: $(INFO_DEPS) $(top_srcdir)/mkinstalldirs $(infodir) for file in $(INFO_DEPS); do \ - for ifile in $(srcdir)/$${file}*; do \ + for ifile in `cd $(srcdir) && echo $${file}*`; do \ $(INSTALL_DATA) $(srcdir)/$$ifile $(infodir)/$$ifile; \ done; \ done @@ -192,7 +192,7 @@ uninstall-pkgdataDATA: rm -f $(pkgdatadir)/$$p; \ done -ID: $(HEADERS) $(SOURCES) +ID: $(HEADERS) $(SOURCES) here=`pwd` && cd $(srcdir) && mkid -f $$here/ID $(SOURCES) $(HEADERS) tags: TAGS @@ -235,10 +235,10 @@ dist: $(DEP_DISTFILES) done @for dir in $(DIST_SUBDIRS); do \ echo copying directory $$dir; \ - tar -chf - $$dir | (cd $(distdir) && tar -xBpf -); \ + tar chf - $$dir | (cd $(distdir) && tar xBpf -); \ done chmod -R a+r $(distdir) - tar -chozf $(distdir).tar.gz $(distdir) + tar chozf $(distdir).tar.gz $(distdir) rm -rf $(distdir) all: info $(SCRIPTS) $(DATA) diff --git a/TODO b/TODO index d4f62adf..4739ee90 100644 --- a/TODO +++ b/TODO @@ -9,6 +9,11 @@ Top priorities: * am_error should use printf-style arguments (for eventual gettext scheme) +--install-missing should only install COPYRIGHT when --gnu or better. + +if configure.in not found, move up a directory and try again? This +could eliminate a common source of problems. + uninstall and pkg-dirs should rm -rf the dir. In general most .am files should be merged into automake. For @@ -49,6 +54,10 @@ Should 'distclean' remove $(SCRIPTS)? Should 'maintainer-clean' do "rm -rf .deps"? Should look for clean-local targets in Makefile.am. +If 'foo' is in SCRIPTS, and 'foo.in' exists, generate code to rebuild +by running configure. Also, ensure that 'foo' is listed in AC_OUTPUT +line. + Think about writing a small tool to guess what the local Makefile.am should look like. @@ -62,10 +71,6 @@ package by GNU standards or by automake? Some things for --strictness=gnits: * "cd $(foo); something" is an error in a rule. Should be: "cd $(foo) && something" -* check for version number in NEWS file. - -Maybe it should be possible to disable all GNU-specific things with ---no-gnu? --ignore-standards? But what? And why? Allow ".h" files to appear in blah_SOURCES; just write them out of existence. [ This is nixed for now because of the auto-dependency @@ -99,10 +104,6 @@ I agree, but I don't see how to implement this yet. Should COPYING.LIB be distributed? -Look at configure.in to see if NLS support is used. Then require the -file ABOUT-NLS. Be sure to write this so that other configure.in -tweaks are easy. - Check all source files to make sure that FSF address is up-to-date. --gnits or --gnu only. @@ -140,7 +141,8 @@ together and rules are in the usual order. Make the output minimal: only output definitions for variables that are used. -Look at dist's jmake for ideas. [what is this?] +Look at dist's jmake for ideas. dist is the name of the distribution +including Metaconfig. Perl uses it. Should handle directory hierarchies deeper than 2. Right now there is no support for this at all. diff --git a/automake.in b/automake.in index cd8fa552..98315320 100755 --- a/automake.in +++ b/automake.in @@ -100,6 +100,9 @@ sub parse_arguments local (@arglist) = @_; local (@make_list); + # Start off as normal. + &set_strictness ('normal'); + while (@arglist) { if ($arglist[0] eq "--version") @@ -1204,12 +1207,15 @@ sub handle_phony ################################################################ # Scan configure.in for interesting things. +# FIXME ensure VERSION, PACKAGE are set. sub scan_configure { open (CONFIGURE, 'configure.in') || die "automake: couldn't open configure.in: $!\n"; local ($seen_make_set) = 0; + local ($seen_prog_install) = 0; + local ($seen_arg_prog) = 0; while () { # Populate libobjs array. @@ -1245,12 +1251,37 @@ sub scan_configure $libsources{$1 . '.c'} = 1; } + # Check for NLS support. + if (/ud_GNU_GETTEXT/) + { + &am_error + ("ud_GNU_GETTEXT in configure.in but SUBDIRS not defined") + if ! defined $contents{'SUBDIRS'}; + &am_error ("ud_GNU_GETTEXT if configure.in but po not in SUBDIRS") + if $contents{'SUBDIRS'} !~ /\/; + &am_error + ("ud_GNU_GETTEXT if configure.in but intl not in SUBDIRS") + if $contents{'SUBDIRS'} !~ /\/; + + &require_file ($NORMAL, 'ABOUT-NLS'); + } + + # Some things required by Automake. FIXME we only really + # require fp_PROG_INSTALL if some scripts are installed. And + # we only really require AC_ARG_PROGRAM if any program is + # installed. $seen_make_set = 1 if /AC_PROG_MAKE_SET/; + $seen_prog_install = 1 if /fp_PROG_INSTALL/; + $seen_arg_prog = 1 if /AC_ARG_PROGRAM/; } # If SUBDIRS defined, require AC_PROG_MAKE_SET. &am_error ("AC_PROG_MAKE_SET must be used in configure.in") if defined $contents{'SUBDIRS'} && ! $seen_make_set; + &am_error ("fp_PROG_INSTALL must be used in configure.in") + unless $seen_prog_install; + &am_error ("AC_ARG_PROGRAM must be used in configure.in") + unless $seen_arg_prog; close (CONFIGURE); } diff --git a/lib/am/Makefile.am b/lib/am/Makefile.am index 8ad51a9a..6d2c9188 100644 --- a/lib/am/Makefile.am +++ b/lib/am/Makefile.am @@ -1,3 +1,5 @@ +## Process this file with automake to create Makefile.in + AUTOMAKE_OPTIONS = gnits bin_SCRIPTS = automake