1 # ---------- other tests and settings ---------
3 AC_CHECK_TYPE([spinlock_t],
4 [AC_DEFINE(HAVE_SPINLOCK_T, 1, [spinlock_t is defined])],
6 [#include <linux/spinlock.h>])
8 # --------- unsigned long long sane? -------
10 AC_CHECK_SIZEOF(unsigned long long, 0)
11 echo "---> size SIZEOF $SIZEOF_unsigned_long_long"
12 echo "---> size SIZEOF $ac_cv_sizeof_unsigned_long_long"
13 if test $ac_cv_sizeof_unsigned_long_long != 8 ; then
14 AC_MSG_ERROR([** we assume that sizeof(long long) == 8. Tell phil@clusterfs.com])
17 # directories for binaries
19 bindir='${exec_prefix}/usr/bin'
20 sbindir='${exec_prefix}/usr/sbin'
21 includedir='${prefix}/usr/include'
23 rootsbindir='${exec_prefix}/sbin'
26 # Directories for documentation and demos.
27 docdir='${prefix}/usr/share/doc/$(PACKAGE)'
29 demodir='$(docdir)/demo'
31 pkgexampledir='${prefix}/usr/lib/$(PACKAGE)/examples'
32 AC_SUBST(pkgexampledir)
33 pymoddir='${prefix}/usr/lib/${PACKAGE}/python/Lustre'
35 # for substitution in lconf
36 PYMOD_DIR="/usr/lib/$PACKAGE/python"
38 modulenetdir='$(moduledir)/net/$(PACKAGE)'
39 AC_SUBST(modulenetdir)
42 # ---------- BAD gcc? ------------
45 AC_MSG_CHECKING([for buggy compiler])
46 CC_VERSION=`$CC -v 2>&1 | grep "^gcc version"`
48 AC_MSG_RESULT([buggy compiler found!])
51 echo " has been known to generate bad code, "
52 echo " please get an updated compiler."
55 TMP_VERSION=`echo $CC_VERSION | cut -c 1-16`
56 if test "$TMP_VERSION" = "gcc version 2.95"; then
60 # ost_pack_niobuf putting 64bit NTOH temporaries on the stack
61 # without "sub $0xc,%esp" to protect the stack from being
62 # stomped on by interrupts (bug 606)
63 "gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)")
66 # mandrake's similar sub 0xc compiler bug
67 # http://marc.theaimsgroup.com/?l=linux-kernel&m=104748366226348&w=2
68 "gcc version 2.96 20000731 (Mandrake Linux 8.1 2.96-0.62mdk)")
72 AC_MSG_RESULT([no known problems])
75 # end ------ BAD gcc? ------------
77 # -------- Check for required packages --------------
79 # this doesn't seem to work on older autoconf
80 # AC_CHECK_LIB(readline, readline,,)
81 AC_MSG_CHECKING([for readline support])
82 AC_ARG_ENABLE(readline,
83 AC_HELP_STRING([--disable-readline],
84 [do not use readline library]),
85 [],[enable_readline='yes'])
86 AC_MSG_RESULT([$enable_readline])
87 if test x$enable_readline = xyes ; then
88 LIBREADLINE="-lreadline -lncurses"
89 AC_DEFINE(HAVE_LIBREADLINE, 1, [readline library is available])
95 AC_MSG_CHECKING([if efence debugging support is requested])
97 AC_HELP_STRING([--enable-efence],
98 [use efence library]),
99 [],[enable_efence='no'])
100 AC_MSG_RESULT([$enable_efence])
101 if test "$enable_efence" = "yes" ; then
103 AC_DEFINE(HAVE_LIBEFENCE, 1, [libefence support is requested])