* configure.ac (YACC): Do not add `-d' here...

* src/Makefile.am (AM_YFLAGS): ... do it here.
(BUILT_SOURCES): New variable.
This commit is contained in:
Alexandre Duret-Lutz 2004-03-08 17:53:54 +00:00
parent 249a114f29
commit 1d411fa3c1
3 changed files with 31 additions and 11 deletions

View file

@ -1,5 +1,9 @@
2004-03-08 Alexandre Duret-Lutz <adl@src.lip6.fr> 2004-03-08 Alexandre Duret-Lutz <adl@src.lip6.fr>
* configure.ac (YACC): Do not add `-d' here...
* src/Makefile.am (AM_YFLAGS): ... do it here.
(BUILT_SOURCES): New variable.
* doc/texinfo.tex: New upstream version. * doc/texinfo.tex: New upstream version.
2004-02-11 Alexandre Duret-Lutz <adl@src.lip6.fr> 2004-02-11 Alexandre Duret-Lutz <adl@src.lip6.fr>

View file

@ -1,8 +1,8 @@
# Process this file with autoconf to produce a configure script. # Process this file with autoconf to produce a configure script.
AC_PREREQ([2.53]) AC_PREREQ([2.53])
AC_INIT([lbtt], [1.0.1], [heikki.tauriainen@hut.fi]) AC_INIT([lbtt], [1.0.3], [heikki.tauriainen@hut.fi])
AC_REVISION([Revision: 1.1]) AC_REVISION([Revision: 1.3])
AC_CONFIG_SRCDIR([src/main.cc]) AC_CONFIG_SRCDIR([src/main.cc])
AM_INIT_AUTOMAKE AM_INIT_AUTOMAKE
AM_CONFIG_HEADER([config.h]) AM_CONFIG_HEADER([config.h])
@ -18,10 +18,6 @@ AC_PROG_CXXCPP
AM_PROG_LEX AM_PROG_LEX
AC_PROG_YACC AC_PROG_YACC
YACC="${YACC} -d"
# Check whether the user has explicitly disabled the test for the availability # Check whether the user has explicitly disabled the test for the availability
# of the GNU readline library. # of the GNU readline library.
@ -37,7 +33,7 @@ AC_ARG_WITH([readline],
# Check for the availability of headers. # Check for the availability of headers.
AC_HEADER_STDC AC_HEADER_STDC
AC_CHECK_HEADERS([fcntl.h obstack.h stdlib.h unistd.h]) AC_CHECK_HEADERS([fcntl.h])
# Check for the availability of the GNU readline headers. # Check for the availability of the GNU readline headers.
@ -51,6 +47,22 @@ fi
AC_LANG([C++]) AC_LANG([C++])
# Check for the availability of the obstack.h header. GNU libc 2.3.2 includes a
# version of this header that cannot be compiled using g++; enable a workaround
# if necessary.
AC_CHECK_HEADERS([obstack.h],
[AC_MSG_CHECKING([whether obstack.h compilation workaround is needed])
AC_TRY_COMPILE([#include <obstack.h>],
[#if __GLIBC__ == 2 && __GLIBC_MINOR__ == 3
obstack_alloc(0, 0);
#endif],
[AC_MSG_RESULT([no])],
[AC_MSG_RESULT([yes])
AC_DEFINE([GLIBC_OBSTACK_WORKAROUND],
[1],
[Define to 1 to enable an obstack.h C++ compilation workaround for GNU libc 2.3.])])])
# Check for the availablility of the sstream or strstream header. # Check for the availablility of the sstream or strstream header.
AC_CHECK_HEADERS([sstream], AC_CHECK_HEADERS([sstream],
@ -131,11 +143,11 @@ AC_C_INLINE
# Checks for library functions. # Checks for library functions.
AC_TYPE_SIGNAL AC_TYPE_SIGNAL
AC_CHECK_FUNCS([mkdir strchr strtod strtol strtoul getopt_long]) AC_CHECK_FUNCS([mkdir strchr strtod strtol strtoul getopt_long isatty])
if test x"${ac_cv_func_getopt_long}" = xno; then if test x"${ac_cv_func_getopt_long}" = xno; then
AC_LIBOBJ([getopt]) AC_LIBOBJ([getopt])
AC_LIBOBJ([getopt1]) AC_LIBOBJ([getopt1])
AC_CHECK_HEADERS([libintl.h string.h strings.h]) AC_CHECK_HEADERS([libintl.h])
AC_CHECK_FUNCS([memset]) AC_CHECK_FUNCS([memset])
fi fi
@ -147,7 +159,8 @@ if test "${readline}" = yes; then
for READLINELIBS in "-lreadline" "-lreadline -lcurses" "-lreadline -ltermcap" error; do for READLINELIBS in "-lreadline" "-lreadline -lcurses" "-lreadline -ltermcap" error; do
if test "${READLINELIBS}" != error; then if test "${READLINELIBS}" != error; then
LIBS="${oldlibs} ${READLINELIBS}" LIBS="${oldlibs} ${READLINELIBS}"
AC_TRY_LINK([#include <${rl_history_h}> AC_TRY_LINK([#include <stdio.h>
#include <${rl_history_h}>
#include <${rl_readline_h}>], #include <${rl_readline_h}>],
[using_history(); readline(""); add_history("");], [using_history(); readline(""); add_history("");],
[break]) [break])

View file

@ -1,3 +1,6 @@
BUILT_SOURCES = Config-parse.h NeverClaim-parse.h
AM_YFLAGS = -d
bin_PROGRAMS = lbtt lbtt-translate bin_PROGRAMS = lbtt lbtt-translate
lbtt_SOURCES = \ lbtt_SOURCES = \
BitArray.cc \ BitArray.cc \