AC_INIT(xcopilot.c)
AM_INIT_AUTOMAKE(xcopilot, 0.6.6)
AM_CONFIG_HEADER(config.h)
AC_PREFIX_DEFAULT(/usr/X11R6)
AC_PROG_CC
AC_PROG_MAKE_SET
AC_CHECK_HEADERS(sys/select.h)
AC_C_BIGENDIAN
AC_PATH_XTRA

AC_MSG_CHECKING(if XShm is enabled)
AC_ARG_ENABLE(xshm, [  --disable-xshm          Do NOT use XShm Extension],
              [if test $enableval = no; then 
                AC_MSG_RESULT(no)
               else if test $enableval = yes; then
                AC_DEFINE(USE_XSHM)
                AC_MSG_RESULT(yes)
               fi
               fi],
              AC_DEFINE(USE_XSHM)
              AC_MSG_RESULT(yes))

AC_FUNC_ALLOCA
AC_CHECK_FUNCS(strsep)
AC_CHECK_SIZEOF(char)
AC_CHECK_SIZEOF(int)
AC_CHECK_SIZEOF(short)
AC_CHECK_SIZEOF(long)
AC_CHECK_SIZEOF(unsigned char)
AC_CHECK_SIZEOF(unsigned int)
AC_CHECK_SIZEOF(unsigned short)
AC_CHECK_SIZEOF(unsigned long)
AC_PROG_RANLIB
AC_PROG_INSTALL
AC_OUTPUT(Makefile mc68k/Makefile mx/Makefile)
