summaryrefslogtreecommitdiffhomepage
path: root/configure.in
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@gnu.org>2001-03-22 03:01:01 +0000
committerJose Antonio Ortega Ruiz <jao@gnu.org>2001-03-22 03:01:01 +0000
commit1c345e559710ec6200f7d508629bd24457a20a80 (patch)
tree4ebccd7c4719cf56da7151af6659992bd1dbb276 /configure.in
parent50375f34b611281a3b05a37221e2baa143f5f5ca (diff)
downloadmdk-1c345e559710ec6200f7d508629bd24457a20a80.tar.gz
mdk-1c345e559710ec6200f7d508629bd24457a20a80.tar.bz2
initial import (sf 0.3beta)
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in118
1 files changed, 118 insertions, 0 deletions
diff --git a/configure.in b/configure.in
new file mode 100644
index 0000000..c27cde4
--- /dev/null
+++ b/configure.in
@@ -0,0 +1,118 @@
+# Copyright (C) 2000, 2001 Free Software Foundation, Inc.
+#
+# This file is free software; as a special exception the author gives
+# unlimited permission to copy and/or distribute it, with or without
+# modifications, as long as this notice is preserved.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+
+AC_INIT(mixlib/mix.h)
+AM_CONFIG_HEADER(config.h)
+AM_INIT_AUTOMAKE(mdk,0.3)
+
+AM_MAINTAINER_MODE
+
+AC_ISC_POSIX
+AC_PROG_CC
+AM_PROG_CC_STDC
+AC_HEADER_STDC
+
+AM_PROG_LEX
+AC_PROG_RANLIB
+
+dnl i18n stuff
+ALL_LINGUAS=""
+AM_GNU_GETTEXT
+
+test "x$prefix" = xNONE && prefix=$ac_default_prefix
+
+AC_DEFINE_UNQUOTED(LOCALEDIR, "${prefix}/share/locale")
+
+dnl Check for readline and history
+AC_ARG_WITH(readline,
+[ --with-readline build mixvm with readline support],
+[case "${withval}" in
+ yes) readl=true ;;
+ no) readl=false ;;
+ *) AC_MSG_ERROR(bad value ${withval} for --with-readline) ;;
+esac], [readl=true])
+
+if test x$readl = xtrue; then
+ AC_CHECK_LIB(ncurses, initscr, ,
+ [AC_MSG_WARN(Cannot find ncurses lib) readl=false])
+fi
+
+if test x$readl = xtrue; then
+ AC_CHECK_LIB(readline, readline, ,
+ [AC_MSG_WARN(Cannot find GNU readline lib) readl=false])
+fi
+
+if test x$readl = xtrue; then
+AC_CHECK_LIB(history, add_history, ,
+ [AC_MSG_WARN(Cannot find GNU history lib) readl=false])
+fi
+
+dnl Check for glib
+AM_PATH_GLIB(1.2.0,
+ [LIBS="$LIBS $GLIB_LIBS" CFLAGS="$CFLAGS $GLIB_CFLAGS"],
+ AC_MSG_ERROR(Cannot find GLIB), "gmodule" )
+
+dnl Check if the gtk gui is required
+AC_ARG_ENABLE(gui,
+[ --enable-gui build the GTK+ GUI for mixvm (gmixvm)],
+[case "${enableval}" in
+ yes) gui=true ;;
+ no) gui=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-gui) ;;
+esac],[gui=true])
+
+dnl Check for gtk+
+if test x$gui = xtrue; then
+ AM_PATH_GTK(1.2.0,
+ [LIBS="$LIBS $GTK_LIBS" CFLAGS="$CFLAGS $GTK_CFLAGS"],
+ [AC_MSG_WARN(Cannot find GTK+: the GUI shall not be built) gui=false],
+ "gmodule" )
+fi
+
+dnl Check for libglade
+if test x$gui = xtrue; then
+ AM_PATH_LIBGLADE([LIBS="$LIBS $LIBGLADE_LIBS"
+ CFLAGS="$CFLAGS $LIBGLADE_CFLAGS"],
+ [AC_MSG_WARN(Cannot find GTK+: the GUI shall not be built) gui=false])
+fi
+
+AM_CONDITIONAL(MAKE_GUI, test x$gui = xtrue)
+
+CFLAGS="$CFLAGS -Wall"
+AC_SUBST(CFLAGS)
+
+AC_OUTPUT(
+Makefile
+doc/Makefile
+doc/html/Makefile
+mixlib/Makefile
+mixlib/testsuite/Makefile
+mixutils/Makefile
+mixgtk/Makefile
+misc/Makefile
+intl/Makefile
+samples/Makefile
+po/Makefile.in
+)
+
+if test x$readl = xtrue; then
+ addinfo=", with readline support"
+fi
+
+echo
+echo "*** GNU MDK $VERSION has been successfully configured. ***"
+echo
+echo "Type make to build the following utilities:"
+echo " - mixasm (MIX assembler${addinfo})"
+echo " - mixvm (MIX virtual machine)"
+if test x$gui = xtrue; then
+echo " - gmixvm (mixvm GTK+ GUI)"
+fi
+echo