diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 86 |
1 files changed, 86 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac new file mode 100644 index 0000000..e51e497 --- /dev/null +++ b/configure.ac @@ -0,0 +1,86 @@ +dnl Configure script for GNU Mach. +dnl Copyright 1997, 1998, 1999, 2004, 2006 Free Software Foundation, Inc. + +dnl Permission to use, copy, modify and distribute this software and its +dnl documentation is hereby granted, provided that both the copyright +dnl notice and this permission notice appear in all copies of the +dnl software, derivative works or modified versions, and any portions +dnl thereof, and that both notices appear in supporting documentation. +dnl +dnl THE FREE SOFTWARE FOUNDATION ALLOWS FREE USE OF THIS SOFTWARE IN ITS +dnl "AS IS" CONDITION. THE FREE SOFTWARE FOUNDATION DISCLAIMS ANY +dnl LIABILITY OF ANY KIND FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE +dnl USE OF THIS SOFTWARE. + +AC_PREREQ([2.57]) + +m4_include([version.m4]) +AC_INIT([AC_PACKAGE_NAME], [AC_PACKAGE_VERSION], [AC_PACKAGE_BUGREPORT], [AC_PACKAGE_TARNAME]) +AC_CONFIG_SRCDIR([kern/ipc_kobject.c]) + +# +# Deduce output var `systype' from configuration parms. +# +AC_CANONICAL_HOST + +case "$host_cpu" in +i[[3456]]86) systype=i386 ;; +*) AC_MSG_ERROR([unsupported CPU type]) ;; +esac + +AC_SUBST([systype]) + +# Default prefix is / for the kernel. +AC_PREFIX_DEFAULT([]) + +# +# Options +# +AC_ARG_ENABLE([kdb], +AS_HELP_STRING([--enable-kdb], [enable use of in-kernel debugger])) +[if test x"$enable_kdb" = xyes; then] + AC_DEFINE([MACH_KDB], [1], [enable use of in-kernel debugger]) +[fi] + +AC_ARG_ENABLE([kmsg], +AS_HELP_STRING([--disable-kmsg], [disable use of kmsg device])) +[if test x"$enable_kmsg" != xno; then] + AC_DEFINE([MACH_KMSG], [], [enable use of kmsg device]) +[fi] + +# +# Programs +# + +AC_PROG_INSTALL +AC_PROG_AWK +AC_PROG_CC +AC_PROG_CPP +AC_PROG_RANLIB + +AC_CHECK_TOOL([AR], [ar]) +AC_CHECK_TOOL([LD], [ld]) +AC_CHECK_TOOL([NM], [nm]) +AC_CHECK_TOOL([STRIP], [strip]) + +AC_CHECK_TOOL([MIG], [mig], [mig]) + +AC_CHECK_PROG([GZIP], [gzip], [gzip], false) +AC_CHECK_PROG([MBCHK], [mbchk], [mbchk], :) + +# Set up `machine' and `mach/machine' links in the build directory for easier +# header file location. +AC_CONFIG_LINKS([machine:${systype}/${systype} + mach/machine:${systype}/include/mach/${systype}]) + + +AC_CONFIG_SUBDIRS([linux]) + +# Do machine-specific configuration last so that it can override anything +# set above if necessary. +if test "$systype" = i386; then + AC_CONFIG_SUBDIRS([i386]) +fi + +AC_CONFIG_FILES([Makefile Makerules version.c doc/Makefile]) +AC_OUTPUT |