* automake.in (&rule_define): When you discover a suffix rules,
authorAkim Demaille <akim@epita.fr>
Mon, 9 Apr 2001 14:46:45 +0000 (14:46 +0000)
committerAkim Demaille <akim@epita.fr>
Mon, 9 Apr 2001 14:46:45 +0000 (14:46 +0000)
register the extensions for .SUFFIXES.
(&handle_texinfo): Don't register the suffixes.
(&get_object_extension): Don't register suffixes, let them be
discovered in depend2.am.
(&handle_emacs_lisp): Depend on your lisp.am.
* lisp.am: Include the rule &handle_emacs_lisp used to output.

ChangeLog
Makefile.in
automake.in
compile.am
lib/am/compile.am
lib/am/libtool.am
lib/am/lisp.am
lib/am/texinfos.am
libtool.am
lisp.am
texinfos.am

index e813a4a..d3b16ad 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 2001-04-09  Akim Demaille  <akim@epita.fr>
 
+       * automake.in (&rule_define): When you discover a suffix rules,
+       register the extensions for .SUFFIXES.
+       (&handle_texinfo): Don't register the suffixes.
+       (&get_object_extension): Don't register suffixes, let them be
+       discovered in depend2.am.
+       (&handle_emacs_lisp): Depend on your lisp.am.
+       * lisp.am: Include the rule &handle_emacs_lisp used to output.
+
+2001-04-09  Akim Demaille  <akim@epita.fr>
+
        * subdirs.am: Don't define info related recursive targets.
        * texinfos.am: Do.
 
index 6c61643..df1566f 100644 (file)
@@ -145,7 +145,7 @@ DIST_SUBDIRS = $(SUBDIRS)
 all: all-recursive
 
 .SUFFIXES:
-.SUFFIXES: .dvi .info .ps .texi .texinfo .txi
+.SUFFIXES: .dvi .info .ps .texi
 
 $(srcdir)/Makefile.in:  Makefile.am  $(top_srcdir)/configure.in $(ACLOCAL_M4)
        cd $(top_srcdir) && \
index 55885e4..3422b83 100755 (executable)
@@ -2696,7 +2696,6 @@ sub handle_texinfo
                                      ('TEXICLEAN' => $texiclean));
 
     push (@dist_targets, 'dist-info');
-    push (@suffixes, '.texi', '.texinfo', '.txi', '.info', '.dvi', '.ps');
 
     if (! defined $options{'no-installinfo'})
     {
@@ -4015,16 +4014,6 @@ sub handle_emacs_lisp
 
     if (@elfiles)
     {
-       # Found some lisp.
-       &define_configure_variable ('lispdir');
-       &define_configure_variable ('EMACS');
-       $output_rules .= (".el.elc:\n"
-                         . "\t\@echo 'WARNING: Warnings can be ignored. :-)'\n"
-                         . "\tif test \$(EMACS) != no; then \\\n"
-                         . "\t  EMACS=\$(EMACS) \$(SHELL) \$(srcdir)/elisp-comp \$<; \\\n"
-                         . "\tfi\n");
-       push (@suffixes, '.el', '.elc');
-
        # Generate .elc files.
        grep ($_ .= 'c', @elfiles);
        &define_pretty_variable ('ELCFILES', '', @elfiles);
@@ -6270,19 +6259,16 @@ sub rule_define ($$$$)
 
 
   # Check the rule for being a suffix rule. If so, store in a hash.
-  my $source_suffix;
-  my $object_suffix;
 
-  if (($source_suffix, $object_suffix) = ($1 =~ $SUFFIX_RULE_PATTERN))
+  if ((my ($source_suffix, $object_suffix)) = ($1 =~ $SUFFIX_RULE_PATTERN))
   {
     $suffix_rules{$source_suffix} = $object_suffix;
     print "Sources ending in .$source_suffix become .$object_suffix\n"
       if $verbose;
     $source_suffix_pattern = "(" . join ('|', keys %suffix_rules) . ")";
+    # Set SUFFIXES from suffix_rules.
+    push @suffixes, ".$source_suffix", ".$object_suffix";
   }
-
-  # FIXME: make sure both suffixes are in SUFFIXES? Or set SUFFIXES from
-  # suffix_rules?
 }
 
 ################################################################
index f47c2e0..6f6909e 100644 (file)
@@ -22,7 +22,6 @@ CPPFLAGS = @CPPFLAGS@
 LDFLAGS = @LDFLAGS@
 LIBS = @LIBS@
 
-
 mostlyclean-am: mostlyclean-compile
 mostlyclean-compile:
 ## Don't remove 'core.*' because some distributions have eg "core.c".
index f47c2e0..6f6909e 100644 (file)
@@ -22,7 +22,6 @@ CPPFLAGS = @CPPFLAGS@
 LDFLAGS = @LDFLAGS@
 LIBS = @LIBS@
 
-
 mostlyclean-am: mostlyclean-compile
 mostlyclean-compile:
 ## Don't remove 'core.*' because some distributions have eg "core.c".
index e65e644..71ae829 100644 (file)
@@ -16,6 +16,7 @@
 ## along with this program; if not, write to the Free Software
 ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 ## 02111-1307, USA.
+
 .PHONY: mostlyclean-libtool clean-libtool distclean-libtool
 mostlyclean-am: mostlyclean-libtool
 mostlyclean-libtool:
index 9502075..323cda4 100644 (file)
 ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 ## 02111-1307, USA.
 
+
+## ---------- ##
+## Building.  ##
+## ---------- ##
+
+EMACS = @EMACS@
+lispdir = @lispdir@
+
+.el.elc:
+       @echo 'WARNING: Warnings can be ignored. :-)'
+       if test $(EMACS) != no; then \
+         EMACS=$(EMACS) $(SHELL) $(srcdir)/elisp-comp $<; \
+       fi
+
 ## ------------ ##
 ## Installing.  ##
 ## ------------ ##
index 0d08fd4..0261ad0 100644 (file)
@@ -35,6 +35,11 @@ endif %?SUBDIRS%
 info-am: $(INFO_DEPS)
 dvi-am: $(DVIS)
 
+
+## ------------ ##
+## Installing.  ##
+## ------------ ##
+
 ## Look in both . and srcdir because the info pages might have been
 ## rebuilt in the build directory.  Can't cd to srcdir; that might
 ## break a possible install-sh reference.
@@ -90,9 +95,9 @@ install-info-am: $(INFO_DEPS)
        else : ; fi
 
 
-## ------------------------- ##
-## Uninstalling info pages.  ##
-## ------------------------- ##
+## -------------- ##
+## Uninstalling.  ##
+## -------------- ##
 
 ?SUBDIRS?RECURSIVE_TARGETS += uninstall-info-recursive
 ?SUBDIRS?.PHONY uninstall-info: uninstall-info-recursive
@@ -136,8 +141,13 @@ dist-info: $(INFO_DEPS)
        done
 
 
-## How to clean.  The funny name is due to --cygnus influence; in
-## Cygnus mode, `clean-info' is a target that users can use.
+
+## ---------- ##
+## Cleaning.  ##
+## ---------- ##
+
+## The funny name is due to --cygnus influence; in Cygnus mode,
+## `clean-info' is a target that users can use.
 
 .PHONY: mostlyclean-aminfo
 mostlyclean-am: mostlyclean-aminfo
index e65e644..71ae829 100644 (file)
@@ -16,6 +16,7 @@
 ## along with this program; if not, write to the Free Software
 ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 ## 02111-1307, USA.
+
 .PHONY: mostlyclean-libtool clean-libtool distclean-libtool
 mostlyclean-am: mostlyclean-libtool
 mostlyclean-libtool:
diff --git a/lisp.am b/lisp.am
index 9502075..323cda4 100644 (file)
--- a/lisp.am
+++ b/lisp.am
 ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 ## 02111-1307, USA.
 
+
+## ---------- ##
+## Building.  ##
+## ---------- ##
+
+EMACS = @EMACS@
+lispdir = @lispdir@
+
+.el.elc:
+       @echo 'WARNING: Warnings can be ignored. :-)'
+       if test $(EMACS) != no; then \
+         EMACS=$(EMACS) $(SHELL) $(srcdir)/elisp-comp $<; \
+       fi
+
 ## ------------ ##
 ## Installing.  ##
 ## ------------ ##
index 0d08fd4..0261ad0 100644 (file)
@@ -35,6 +35,11 @@ endif %?SUBDIRS%
 info-am: $(INFO_DEPS)
 dvi-am: $(DVIS)
 
+
+## ------------ ##
+## Installing.  ##
+## ------------ ##
+
 ## Look in both . and srcdir because the info pages might have been
 ## rebuilt in the build directory.  Can't cd to srcdir; that might
 ## break a possible install-sh reference.
@@ -90,9 +95,9 @@ install-info-am: $(INFO_DEPS)
        else : ; fi
 
 
-## ------------------------- ##
-## Uninstalling info pages.  ##
-## ------------------------- ##
+## -------------- ##
+## Uninstalling.  ##
+## -------------- ##
 
 ?SUBDIRS?RECURSIVE_TARGETS += uninstall-info-recursive
 ?SUBDIRS?.PHONY uninstall-info: uninstall-info-recursive
@@ -136,8 +141,13 @@ dist-info: $(INFO_DEPS)
        done
 
 
-## How to clean.  The funny name is due to --cygnus influence; in
-## Cygnus mode, `clean-info' is a target that users can use.
+
+## ---------- ##
+## Cleaning.  ##
+## ---------- ##
+
+## The funny name is due to --cygnus influence; in Cygnus mode,
+## `clean-info' is a target that users can use.
 
 .PHONY: mostlyclean-aminfo
 mostlyclean-am: mostlyclean-aminfo