[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
44-fix-ac-decl-yytext.patch
From: |
Akim Demaille |
Subject: |
44-fix-ac-decl-yytext.patch |
Date: |
Wed, 22 Aug 2001 08:28:22 +0200 |
Index: ChangeLog
from Akim Demaille <address@hidden>
* lib/autoconf/programs.m4 (_AC_PROG_LEX_YYTEXT_DECL): Use
AC_TRY_COMMAND.
(AC_DECL_YYTEXT): Fix the previous patch: it points to AC_PROG_LEX.
Index: lib/autoconf/programs.m4
--- lib/autoconf/programs.m4 Tue, 21 Aug 2001 10:46:02 +0200 akim
+++ lib/autoconf/programs.m4 Tue, 21 Aug 2001 11:12:02 +0200 akim
@@ -399,8 +399,11 @@ m4_define([_AC_PROG_LEX_YYTEXT_DECL],
[AC_CACHE_CHECK(lex output file root, ac_cv_prog_lex_root,
[# The minimal lex program is just a single line: %%. But some broken lexes
# (Solaris, I think it was) want two %% lines, so accommodate them.
-echo '%%
-%%' | $LEX
+cat >conftest.l <<_ACEOF
+%%
+%%
+_ACEOF
+AC_TRY_COMMAND($LEX conftest.l)
if test -f lex.yy.c; then
ac_cv_prog_lex_root=lex.yy
elif test -f lexyy.c; then
@@ -408,8 +411,8 @@ m4_define([_AC_PROG_LEX_YYTEXT_DECL],
else
AC_MSG_ERROR([cannot find output from $LEX; giving up])
fi])
-LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
-AC_SUBST(LEX_OUTPUT_ROOT)dnl
+rm -f conftest.l
+AC_SUBST([LEX_OUTPUT_ROOT], [$ac_cv_prog_lex_root])dnl
AC_CACHE_CHECK(whether yytext is a pointer, ac_cv_prog_lex_yytext_pointer,
[# POSIX says lex can declare yytext either as a pointer or an array; the
@@ -433,7 +436,7 @@ m4_define([_AC_PROG_LEX_YYTEXT_DECL],
# Require AC_PROG_LEX in case some people were just calling this macro.
-AU_DEFUN([AC_DECL_YYTEXT], [_AC_PROG_LEX_YYTEXT_DECL])
+AU_DEFUN([AC_DECL_YYTEXT], [AC_PROG_LEX])
# AC_PROG_LN_S
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- 44-fix-ac-decl-yytext.patch,
Akim Demaille <=