AC_PROG_CC
gl_EARLY
AC_PROG_CPP
+AC_PROG_SED
AC_PROG_AWK
dnl Gnulib.
AM_PATH_LISPDIR
+AC_DEFINE_UNQUOTED([HOST_TYPE], ["$host"],
+ [Define to the host's GNU triplet.])
+
#--------------------------------------------------------------------
#
# User options (after above tests that may set default CFLAGS etc.)
AC_MSG_ERROR([GNU MP 4.1 or greater not found, see README]))
dnl GNU libunistring is checked for by Gnulib's `libunistring' module.
+if test "x$LTLIBUNISTRING" != "x"; then
+ LIBS="$LTLIBUNISTRING $LIBS"
+else
+ AC_MSG_ERROR([GNU libunistring is required, please install it.])
+fi
dnl i18n tests
#AC_CHECK_HEADERS([libintl.h])
setprotoent getprotoent endprotoent dnl
setservent getservent endservent dnl
getnetbyaddr getnetbyname dnl
- inet_lnaof inet_makeaddr inet_netof hstrerror dnl
- inet_pton inet_ntop)
+ inet_lnaof inet_makeaddr inet_netof hstrerror)
# struct sockaddr field sin_len is only present on BSD systems.
# On 4.4BSD apparently a #define SIN_LEN exists, but on other BSD systems
[],
[AC_MSG_WARN(Guessing that stack grows down -- see scmconfig.h)])
+#--------------------------------------------------------------------
+#
+# Boehm's GC library
+#
+#--------------------------------------------------------------------
+PKG_CHECK_MODULES([BDW_GC], [bdw-gc])
+
+CFLAGS="$BDW_GC_CFLAGS $CFLAGS"
+LIBS="$BDW_GC_LIBS $LIBS"
+
+# `GC_do_blocking ()' is available in GC 7.1 but not declared.
+AC_CHECK_FUNCS([GC_do_blocking])
+AC_CHECK_DECL([GC_do_blocking],
+ [AC_DEFINE([HAVE_DECL_GC_DO_BLOCKING], [1],
+ [Define this if the `GC_do_blocking ()' function is declared])],
+ [],
+ [#include <gc/gc.h>])
+
+# `GC_fn_type' is not available in GC 7.1 and earlier.
+AC_CHECK_TYPE([GC_fn_type],
+ [AC_DEFINE([HAVE_GC_FN_TYPE], [1],
+ [Define this if the `GC_fn_type' type is available.])],
+ [],
+ [#include <gc/gc.h>])
+
+
AC_CHECK_SIZEOF(float)
if test "$ac_cv_sizeof_float" -le "$ac_cv_sizeof_long"; then
AC_DEFINE(SCM_SINGLES, 1,
CFLAGS="$old_CFLAGS"
AC_MSG_RESULT($works)
+GUILE_THREAD_LOCAL_STORAGE
+
fi # with_threads=pthreads
AC_SUBST(GUILE_FOR_BUILD)
## If we're using GCC, ask for aggressive warnings.
+GCC_CFLAGS=""
case "$GCC" in
yes )
## We had -Wstrict-prototypes in here for a bit, but Guile does too
## less than exasperating.
## -Wpointer-arith was here too, but something changed in gcc/glibc
## and it became equally exasperating (gcc 2.95 and/or glibc 2.1.2).
- GCC_CFLAGS="-Wall -Wmissing-prototypes"
+ POTENTIAL_GCC_CFLAGS="-Wall -Wmissing-prototypes \
+ -Wdeclaration-after-statement -Wundef \
+ -Wswitch-enum"
# Do this here so we don't screw up any of the tests above that might
# not be "warning free"
if test "${GUILE_ERROR_ON_WARNING}" = yes
then
- GCC_CFLAGS="${GCC_CFLAGS} -Werror"
+ POTENTIAL_GCC_CFLAGS="${POTENTIAL_GCC_CFLAGS} -Werror"
enable_compile_warnings=no
fi
+
+ for flag in $POTENTIAL_GCC_CFLAGS
+ do
+ gl_WARN_ADD([$flag], [GCC_CFLAGS])
+ done
;;
esac
AC_SUBST(GCC_CFLAGS)
+# Check for GNU ld's "-z relro".
+GUILE_GNU_LD_RELRO
+
+
## If we're creating a shared library (using libtool!), then we'll
## need to generate a list of .lo files corresponding to the .o files
## given in LIBOBJS. We'll call it LIBLOBJS.