bug-autoconf
[Top][All Lists]
Advanced

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

Re: Autoheader @ interpolation


From: Akim Demaille
Subject: Re: Autoheader @ interpolation
Date: 22 Oct 2002 13:14:01 +0200
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Honest Recruiter)

>>>>> "Carlos" == Carlos Velasco <address@hidden> writes:
| Carlos> Hi Akim, try to do it this way:
| 
| Carlos> AH_TOP([Email: address@hidden)
| 
| Carlos> In the tests below you use the "@" with space before.
| 
| Ah!  Stupid me :*(
| 
| Thanks.  I'm installing this:
| 
| Index: ChangeLog
| from  Akim Demaille  <address@hidden>
| 
|       * lib/m4sugar/m4sh.m4 (_AS_QUOTE): The warning about quoted
|       characters is a syntax warning now.
|       (_AS_QUOTE): Accept $2 as list of characters to quote.
|       * lib/autoconf/autoheader.m4 (AH_VERBATIM, _AH_VERBATIM_OLD):
|       Quote for Perl, not sh.
|       * bin/autoheader.in: When $debug, report the file which is
|       `do'ne.
|       * tests/tools.at (autom4te, autoheader): Exercise @bar, not merely
|       `@', to tickle Perl's lists.
|       Reported by Carlos Velasco.

And this, to address (i) the problem of quadrigraphs that are no
longer recognized because of \@ (I now use '' strings instead of ""
strings), and (ii) the Libtool failure because of obsolete AC_MSG_*
calls.

Index: ChangeLog
from  Akim Demaille  <address@hidden>

        * tests/foreign.at (Libtool): Don't check autoconf's stderr: there
        are a few warnings.
        * lib/autoconf/autoheader.m4 (AH_VERBATIM, _AH_VERBATIM_OLD):
        Quote for Perl '' strings, not "".
        * bin/autoheader.in: Invoke autoconf to get '' strings, not ""
        strings.

Index: bin/autoheader.in
===================================================================
RCS file: /cvsroot/autoconf/autoconf/bin/autoheader.in,v
retrieving revision 1.125
diff -u -u -r1.125 autoheader.in
--- bin/autoheader.in 22 Oct 2002 08:20:19 -0000 1.125
+++ bin/autoheader.in 22 Oct 2002 11:12:24 -0000
@@ -167,12 +167,12 @@
 
 # Source what the traces are trying to tell us.
 verbose "$me: running $autoconf to trace from $ARGV[0]";
-xsystem ("$autoconf "
+xsystem ("$autoconf"
         # If you change this list, update the
         # `Autoheader-preselections' section of autom4te.in.
-        . " --trace AC_CONFIG_HEADERS:'\$\$config_h ||= \"\$1\";'"
-        . " --trace AH_OUTPUT:'\$\$verbatim{\"\$1\"} = \"\\\n\$2\";'"
-        . " --trace AC_DEFINE_TRACE_LITERAL:'\$\$symbol{\"\$1\"} = 1;'"
+        . ' --trace AC_CONFIG_HEADERS:\'$$config_h ||= \'"\'"\'$1\'"\'"\';\''
+        . ' --trace AH_OUTPUT:\'$$verbatim{\'"\'"\'$1\'"\'"\'} = 
\'"\'"\'$2\'"\'"\';\''
+        . ' --trace AC_DEFINE_TRACE_LITERAL:\'$$symbol{\'"\'"\'$1\'"\'"\'} = 
1;\''
         . " $ARGV[0] >$tmp/traces.pl");
 
 local (%verbatim, %symbol);
@@ -223,7 +223,7 @@
 # Dump the templates from `configure.ac'.
 foreach (sort keys %verbatim)
   {
-    print $out "$verbatim{$_}\n";
+    print $out "\n$verbatim{$_}\n";
   }
 
 # Dump bottom portion of `acconfig.h'.
Index: lib/autoconf/autoheader.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/autoheader.m4,v
retrieving revision 1.3
diff -u -u -r1.3 autoheader.m4
--- lib/autoconf/autoheader.m4 22 Oct 2002 08:20:19 -0000 1.3
+++ lib/autoconf/autoheader.m4 22 Oct 2002 11:12:24 -0000
@@ -65,10 +65,10 @@
 # TEMPLATE associated to the KEY.  Otherwise, do nothing.  TEMPLATE is
 # output as is, with no formatting.
 #
-# Quote for Perl "" strings, which are those used by Autoheader.
+# Quote for Perl '' strings, which are those used by Autoheader.
 m4_define([AH_VERBATIM],
 [AS_LITERAL_IF([$1],
-               [AH_OUTPUT([$1], AS_ESCAPE([[$2]], [\"@$]))])
+               [AH_OUTPUT([$1], AS_ESCAPE([[$2]], [\\'']))])
 ])
 
 
@@ -76,10 +76,10 @@
 # -------------------------------
 # Same as above, but with bugward compatibility.
 #
-# Quote for Perl "" strings, which are those used by Autoheader.
+# Quote for Perl '' strings, which are those used by Autoheader.
 m4_define([_AH_VERBATIM_OLD],
 [AS_LITERAL_IF([$1],
-               [AH_OUTPUT([$1], _AS_QUOTE([[$2]], [\"@$]))])
+               [AH_OUTPUT([$1], _AS_QUOTE([[$2]], [\\'']))])
 ])
 
 
Index: tests/foreign.at
===================================================================
RCS file: /cvsroot/autoconf/autoconf/tests/foreign.at,v
retrieving revision 1.13
diff -u -u -r1.13 foreign.at
--- tests/foreign.at 20 Aug 2001 14:44:38 -0000 1.13
+++ tests/foreign.at 22 Oct 2002 11:12:24 -0000
@@ -70,7 +70,8 @@
 AC_PROG_LIBTOOL
 _EOF
 
-AT_CHECK_AUTOCONF
+# FIXME: Once Libtool really fixed, stop ignoring stderr.
+AT_CHECK_AUTOCONF([], [], [], [ignore])
 
 # Ignore stderr, because ltconfig always loads the cache, which is
 # /dev/null, and some shells choke on this.  For instance with Bash




reply via email to

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