X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=configure.ac;h=5bcc068f95422d814e97bff8bea574ad5038d04c;hp=75bc9af422e40e30ef3f5f95f1286c437690ce1c;hb=8fa47e7b377e6bf3a1d0f87c03cd33c3f1668b98;hpb=909d3caa7a163c5f2ae9712787b5c3925ffd4fc1 diff --git a/configure.ac b/configure.ac index 75bc9af4..5bcc068f 100644 --- a/configure.ac +++ b/configure.ac @@ -81,7 +81,7 @@ AC_TYPE_SIZE_T # Checks for library functions. AC_FUNC_MALLOC AC_FUNC_MMAP -AC_CHECK_FUNCS([gettimeofday munmap strtoul]) +AC_CHECK_FUNCS([gettimeofday munmap strtoul strndup strnlen mkdtemp dirfd]) # Check for MinGW32. MINGW32=no @@ -133,11 +133,24 @@ AC_CHECK_LIB([c], [open_memstream], ] ) +# Check for posix_fallocate +AC_CHECK_LIB([c], [posix_fallocate], +[ + AC_DEFINE_UNQUOTED([BABELTRACE_HAVE_POSIX_FALLOCATE], 1, [Has posix_fallocate support.]) +] +) + +# Check for faccessat +AC_CHECK_LIB([c], [faccessat], +[ + AC_DEFINE_UNQUOTED([BABELTRACE_HAVE_FACCESSAT], 1, [Has faccessat support.]) +] +) + AC_CHECK_LIB([popt], [poptGetContext], [], [AC_MSG_ERROR([Cannot find popt.])] ) - # For Python # SWIG version needed or newer: swig_version=2.0.0 @@ -184,9 +197,12 @@ PKG_CHECK_MODULES(GMODULE, [$pkg_modules]) AC_SUBST(PACKAGE_LIBS) LIBS="$LIBS $GMODULE_LIBS" -PACKAGE_CFLAGS="$GMODULE_CFLAGS -Wall -Wformat -include config.h" +PACKAGE_CFLAGS="$GMODULE_CFLAGS -Wall -Wformat" AC_SUBST(PACKAGE_CFLAGS) +DEFAULT_INCLUDES="-I\$(top_srcdir) -I\$(top_builddir) -I\$(top_builddir)/include -include config.h" +AC_SUBST(DEFAULT_INCLUDES) + babeltraceincludedir="${includedir}/babeltrace" AC_SUBST(babeltraceincludedir)