automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

53-lex-am.patch


From: Akim Demaille
Subject: 53-lex-am.patch
Date: Mon, 19 Mar 2001 10:21:07 +0100

Index: ChangeLog
from  Akim Demaille  <address@hidden>
        * automake.in (&output_lex_build_rule): Output this...
        * lex.am: New file.

Index: Makefile.am
--- Makefile.am Sun, 11 Mar 2001 20:15:57 +0100 akim (am/f/46_Makefile.a 1.17 
644)
+++ Makefile.am Sun, 11 Mar 2001 20:29:13 +0100 akim (am/f/46_Makefile.a 1.17 
644)
@@ -11,11 +11,11 @@
 info_TEXINFOS = automake.texi

 amfiles = check.am clean-hdr.am clean-kr.am clean.am comp-vars.am \
-compile.am configure.am data.am dejagnu.am depend.am depend2.am          \
-distdir.am footer.am header-vars.am header.am install.am java.am  \
-kr-extra.am library.am libs.am libtool.am lisp.am ltlib.am       \
+compile.am configure.am data.am dejagnu.am depend.am depend2.am \
+distdir.am footer.am header-vars.am header.am install.am java.am \
+kr-extra.am lex.am library.am libs.am libtool.am lisp.am ltlib.am \
 ltlibrary.am mans-vars.am mans.am multilib.am program.am progs.am \
-python.am remake-hdr.am remake.am scripts.am subdirs.am tags.am          \
+python.am remake-hdr.am remake.am scripts.am subdirs.am tags.am \
 texi-vers.am texibuild.am texinfos.am yacc.am

 dist_pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 \
Index: Makefile.in
--- Makefile.in Sun, 11 Mar 2001 20:15:57 +0100 akim (am/h/16_Makefile.i 1.46 
644)
+++ Makefile.in Sun, 11 Mar 2001 20:29:17 +0100 akim (am/h/16_Makefile.i 1.46 
644)
@@ -85,11 +85,11 @@
 info_TEXINFOS = automake.texi

 amfiles = check.am clean-hdr.am clean-kr.am clean.am comp-vars.am \
-compile.am configure.am data.am dejagnu.am depend.am depend2.am          \
-distdir.am footer.am header-vars.am header.am install.am java.am  \
-kr-extra.am library.am libs.am libtool.am lisp.am ltlib.am       \
+compile.am configure.am data.am dejagnu.am depend.am depend2.am \
+distdir.am footer.am header-vars.am header.am install.am java.am \
+kr-extra.am lex.am library.am libs.am libtool.am lisp.am ltlib.am \
 ltlibrary.am mans-vars.am mans.am multilib.am program.am progs.am \
-python.am remake-hdr.am remake.am scripts.am subdirs.am tags.am          \
+python.am remake-hdr.am remake.am scripts.am subdirs.am tags.am \
 texi-vers.am texibuild.am texinfos.am yacc.am


Index: automake.in
--- automake.in Sun, 11 Mar 2001 20:21:53 +0100 akim (am/f/39_automake.i 1.172 
755)
+++ automake.in Sun, 11 Mar 2001 20:27:04 +0100 akim (am/f/39_automake.i 1.172 
755)
@@ -1499,9 +1499,9 @@ sub output_yacc_build_rule

     # Generate rule for c/c++.
     $output_rules .= &file_contents ('yacc',
-                                    ('YACC_SUFFIX' => $yacc_suffix,
-                                     'C_SUFFIX'    => $c_suffix,
-                                     'YLWRAP'      => $use_ylwrap));
+                                    ('YLWRAP'      => $use_ylwrap,
+                                     'YACC_SUFFIX' => $yacc_suffix,
+                                     'C_SUFFIX'    => $c_suffix));
 }

 sub output_lex_build_rule
@@ -1510,23 +1510,10 @@ sub output_lex_build_rule

     (my $c_suffix = $lex_suffix) =~ tr/l/c/;

-    push (@suffixes, $lex_suffix);
-    &define_configure_variable ('LEX_OUTPUT_ROOT');
-    &define_configure_variable ('LEXLIB');
-    $output_rules .= "$lex_suffix$c_suffix:\n\t";
-
-    if ($use_ylwrap)
-    {
-        # Is the $@ correct here?  If so, why not use it in the ylwrap
-        # build rule for yacc above?
-       $output_rules .= '$(SHELL) $(YLWRAP)'
-           . ' "$(LEX)" $< $(LEX_OUTPUT_ROOT).c $@ -- $(AM_LFLAGS) $(LFLAGS)';
-    }
-    else
-    {
-       $output_rules .= '$(LEX) $(AM_LFLAGS) $(LFLAGS) $< && mv 
$(LEX_OUTPUT_ROOT).c $@';
-    }
-    $output_rules .= "\n";
+    $output_rules .= &file_contents ('lex',
+                                    ('YLWRAP'     => $use_ylwrap,
+                                     'LEX_SUFFIX' => $lex_suffix,
+                                     'C_SUFFIX'   => $c_suffix));
 }


Index: lex.am
--- lex.am Sun, 11 Mar 2001 20:30:28 +0100 akim ()
+++ lex.am Sun, 11 Mar 2001 20:28:08 +0100 akim (am/h/36_lex.am  644)
@@ -0,0 +1,28 @@
+## automake - create Makefile.in from Makefile.am
+## Copyright 2001 Free Software Foundation, Inc.
+
+## This program is free software; you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation; either version 2, or (at your option)
+## any later version.
+
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+## GNU General Public License for more details.
+
+## You should have received a copy of the GNU General Public License
+## along with this program; if not, write to the Free Software
+## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+## 02111-1307, USA.
+
+LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
+LEXLIB = @LEXLIB@
+
+## Generate rule for c/c++.
+%LEX_SUFFIX%%C_SUFFIX%:
+if %?YLWRAP%
+       $(SHELL) $(YLWRAP) $(LEX) $< $(LEX_OUTPUT_ROOT).c $@ -- $(AM_LFLAGS) 
$(LFLAGS)
+else
+       $(LEX) $(AM_LFLAGS) $(LFLAGS) $< && mv $(LEX_OUTPUT_ROOT).c $@
+endif %?YLWRAP%



reply via email to

[Prev in Thread] Current Thread [Next in Thread]