1 dnl Copyright (C) 2009 Sun Microsystems
2 dnl This file is free software; Sun Microsystems
3 dnl gives unlimited permission to copy and/or distribute it,
4 dnl with or without modifications, as long as this notice is preserved.
6 dnl Check for all of the headers and libs that Drizzle needs. We check all
7 dnl of these for plugins too, to ensure that all of the appropriate defines
10 AC_DEFUN([PANDORA_DRIZZLE_BUILD],[
12 dnl We need to turn on our CXXFLAGS to make sure it shows up correctly
13 save_CXXFLAGS="${CXXFLAGS}"
14 CXXFLAGS="${CXXFLAGS} ${AM_CXXFLAGS}"
16 CXXFLAGS="${save_CXXFLAGS}"
27 PANDORA_WORKING_FDATASYNC
42 AC_CHECK_HEADERS(sys/fpu.h fpu_control.h ieeefp.h)
43 AC_CHECK_HEADERS(select.h sys/select.h)
44 AC_CHECK_HEADERS(utime.h sys/utime.h )
45 AC_CHECK_HEADERS(synch.h sys/mman.h sys/socket.h)
46 AC_CHECK_HEADERS(sched.h)
47 AC_CHECK_HEADERS(sys/prctl.h)
48 AC_CHECK_HEADERS(execinfo.h)
49 AC_CHECK_HEADERS(locale.h)
50 AC_CHECK_HEADERS(termcap.h termio.h termios.h asm/termbits.h)
51 AC_CHECK_HEADERS(paths.h)
54 #--------------------------------------------------------------------
55 # Check for system libraries. Adds the library to $LIBS
56 # and defines HAVE_LIBM etc
57 #--------------------------------------------------------------------
59 # For the sched_yield() function on Solaris
60 AC_CHECK_FUNC(sched_yield, [],
61 [AC_CHECK_LIB(posix4, [sched_yield],
62 [AC_DEFINE(HAVE_SCHED_YIELD, 1, [Have sched_yield function]) LIBS="$LIBS -lposix4"])])
64 AS_IF([test "$ac_cv_header_termio_h" = "no" -a "$ac_cv_header_termios_h" = "no"],[
65 AC_CHECK_FUNC(gtty, [], [AC_CHECK_LIB(compat, gtty)])
68 AC_CHECK_HEADERS([curses.h term.h],[],[],[[
73 AC_CHECK_TYPES([ulong])