eliot/configure.in

117 lines
3.7 KiB
Text
Raw Normal View History

2004-04-08 11:43:06 +02:00
dnl -*-m4-*-
dnl Process this file with autoconf to produce a configure script.
dnl --------------------------------------------------------------
dnl configure.in for Eliot
dnl --------------------------------------------------------------
dnl AC_REVISION($Id: configure.in,v 1.9 2005/03/03 22:14:41 ipkiss Exp $)
AC_INIT(eliot, 1.5-cvs)
2004-06-26 16:47:39 +02:00
AC_CONFIG_SRCDIR(wxwin/main.cc)
AM_INIT_AUTOMAKE
2004-04-08 11:43:06 +02:00
AM_CONFIG_HEADER(config.h)
2004-04-08 11:57:28 +02:00
AM_OPTIONS_WXCONFIG
2004-04-08 11:43:06 +02:00
dnl --------------------------------------------------------------
dnl Checks for programs.
dnl --------------------------------------------------------------
AC_PROG_INSTALL
AC_PROG_CC
AC_PROG_CXX
AC_PROG_MAKE_SET
AC_PROG_RANLIB
dnl --------------------------------------------------------------
dnl Checks for compilation flags
2004-04-08 11:43:06 +02:00
dnl --------------------------------------------------------------
AC_CACHE_CHECK([if \$CC accepts -Wall],
[ac_cv_c_Wall],
[CFLAGS="-Wall ${CFLAGS_save}"
AC_TRY_COMPILE([],,ac_cv_c_Wall=yes, ac_cv_c_Wall=no)])
2004-06-26 16:47:39 +02:00
if test "${ac_cv_c_Wall}" != "no"; then
CFLAGS="-Wall ${CFLAGS_save}"
CXXFLAGS="-Wall ${CXXFLAGS_save}"
2004-04-08 11:57:28 +02:00
fi
2004-04-08 11:43:06 +02:00
dnl --------------------------------------------------------------
dnl Checks for header files.
dnl --------------------------------------------------------------
AC_HEADER_STDC
AC_CHECK_HEADERS(fcntl.h unistd.h sys/wait.h)
2004-04-08 11:43:06 +02:00
dnl --------------------------------------------------------------
dnl Checks for typedefs, structures, and compiler characteristics.
dnl --------------------------------------------------------------
AC_C_CONST
AC_TYPE_SIZE_T
dnl AC_C_BIGENDIAN
2004-06-26 16:47:39 +02:00
AC_C_INLINE
2004-04-08 11:43:06 +02:00
AC_CHECK_SIZEOF(char, 1)
AC_CHECK_SIZEOF(short, 2)
AC_CHECK_SIZEOF(int *, 4)
AC_CHECK_SIZEOF(int, 4)
AC_CHECK_SIZEOF(long, 4)
AC_CHECK_SIZEOF(long long, 0)
dnl --------------------------------------------------------------
dnl Checks for library functions.
dnl --------------------------------------------------------------
AC_FUNC_MEMCMP
dnl --------------------------------------------------------------
dnl Checks for libraries.
dnl --------------------------------------------------------------
dnl Check for wxWidgets
AC_ARG_ENABLE(wxwidgets,
[ --enable-wxwidgets wxWidgets support (default disabled)])
if test "${enable_wxwidgets}" = "yes"
then
AM_PATH_WXCONFIG(2.4.0, wxwin=1)
if test "${wxwin}" != 1; then
AC_MSG_ERROR([
wxWidgets must be installed on your system
but wx-config script couldn't be found.
Please check that wx-config is in path, the directory
where wxWidgets libraries are installed (returned by
'wx-config --libs' command) is in LD_LIBRARY_PATH or
equivalent variable and wxWindows version is 2.4.0 or above.
])
fi
AM_CPPFLAGS="$AM_CPPFLAGS $WX_CPPFLAGS"
AM_CXXFLAGS="$AM_CXXFLAGS $WX_CXXFLAGS_ONLY"
AM_CFLAGS="$AM_CFLAGS $WX_CFLAGS_ONLY"
AM_LDFLAGS="$AM_LDFLAGS $WX_LIBS"
fi
AM_CONDITIONAL([BUILD_WXWIDGETS], [test "${wxwin}" = "1"])
dnl Check for ncurses
AC_ARG_ENABLE(ncurses,
[ --enable-ncurses ncurses interface support (default disabled)])
if test "${enable_ncurses}" = "yes"
then
AC_CHECK_HEADERS(ncurses.h, want_ncurses=1,
[AC_MSG_ERROR([Could not find the ncurses library on your system])])
fi
AM_CONDITIONAL([BUILD_NCURSES], [test "${want_ncurses}" = "1"])
dnl Enable/disable text version
AC_ARG_ENABLE(text,
[ --enable-text text interface support (default enabled)])
AM_CONDITIONAL([BUILD_TEXT], [test "${enable_text}" != "no"])
dnl internationalization macros
AM_GNU_GETTEXT_VERSION(0.11.5)
AM_GNU_GETTEXT
2004-04-08 11:43:06 +02:00
dnl --------------------------------------------------------------
dnl Output
dnl --------------------------------------------------------------
AC_CONFIG_FILES(intl/Makefile po/Makefile.in
2004-06-26 16:47:39 +02:00
dic/Makefile
2004-04-08 11:43:06 +02:00
game/Makefile
2004-06-26 16:47:39 +02:00
wxwin/Makefile
2004-04-08 11:43:06 +02:00
utils/Makefile
Makefile)
2004-06-26 16:47:39 +02:00
AC_OUTPUT