1 dnl Process this file with autoconf to produce a configure script.
4 AC_CONFIG_HEADER(config.h)
20 # Do not cache this, it changes too often in many configurations
23 if test -z "$PLINCL"; then
24 plcandidates="pl swipl swi-prolog"
25 AC_CHECK_PROGS(PL, $plcandidates, "none")
26 AC_CHECK_PROGS(PLLD, plld, "none")
27 if test $PLLD = "none"; then
28 AC_ERROR("Cannot find SWI-Prolog plld utility. SWI-Prolog must be installed first")
30 if test $PL = "none"; then
31 AC_ERROR("Cannot find SWI-Prolog. SWI-Prolog must be installed first")
33 AC_CHECKING("Running $PL -dump-runtime-variables")
34 eval `$PL -dump-runtime-variables`
36 PLINCL=$PLBASE/include
37 AC_MSG_RESULT(" PLBASE=$PLBASE")
38 AC_MSG_RESULT(" PLARCH=$PLARCH")
39 AC_MSG_RESULT(" PLLIBS=$PLLIBS")
40 AC_MSG_RESULT(" PLLDFLAGS=$PLLDFLAGS")
41 AC_MSG_RESULT(" PLSHARED=$PLSHARED")
42 AC_MSG_RESULT(" PLSOEXT=$PLSOEXT")
55 TARGETS="chr_support.$SO"
56 AC_CHECK_PROGS(MAKE, gmake make, "make")
58 if test ! -z "$GCC"; then
59 COFLAGS="${COFLAGS--O2 -fno-strict-aliasing}"
60 CWFLAGS="${CWFLAGS--Wall}"
62 COFLAGS="${COFLAGS--O}"