2008-01-28 02:12:20 +00:00
|
|
|
# -*- Autoconf -*-
|
|
|
|
# Process this file with autoconf to produce a configure script.
|
|
|
|
|
2008-03-05 20:28:22 +00:00
|
|
|
# Autoconf
|
2008-02-25 18:04:01 +00:00
|
|
|
AC_PREREQ(2.59)
|
2011-03-18 21:47:09 +00:00
|
|
|
|
|
|
|
# NOTE: This version is _only_ used for naming the tarball. The
|
|
|
|
# VERSION define is not used by the code. It gets a version string
|
|
|
|
# from 'git describe'; see src/ceph_ver.[ch]
|
2012-11-14 01:29:47 +00:00
|
|
|
|
2014-11-11 17:33:12 +00:00
|
|
|
AC_INIT([ceph], [0.88], [ceph-devel@vger.kernel.org])
|
2012-11-08 20:43:24 +00:00
|
|
|
|
|
|
|
# Create release string. Used with VERSION for RPMs.
|
2013-01-23 17:57:46 +00:00
|
|
|
RPM_RELEASE=0
|
2012-11-08 20:43:24 +00:00
|
|
|
AC_SUBST(RPM_RELEASE)
|
2013-01-23 17:57:46 +00:00
|
|
|
if test -d ".git" ; then
|
|
|
|
AC_CHECK_PROG(GIT_CHECK, git, yes)
|
|
|
|
if test x"$GIT_CHECK" = x"yes"; then
|
|
|
|
RPM_RELEASE=`if expr index $(git describe --always) '-' > /dev/null ; then git describe --always | cut -d- -f2- | tr '-' '.' ; else echo "0"; fi`
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
AC_MSG_NOTICE([RPM_RELEASE='$RPM_RELEASE'])
|
2012-11-08 20:43:24 +00:00
|
|
|
|
2012-10-08 17:04:25 +00:00
|
|
|
AC_CONFIG_MACRO_DIR([m4])
|
2011-03-18 21:47:09 +00:00
|
|
|
|
Use Google Test framework for unit tests.
Use ``make check`` to run the tests.
The src/gtest directory comes from ``svn export
http://googletest.googlecode.com/svn/tags/release-1.5.0 src/gtest``
and running "git add -f src/gtest".
gtest is licensed under the New BSD license, see src/gtest/COPYING.
For more on Google Test, see http://code.google.com/p/googletest/
Changed autogen.sh regenerate gtest automake files too. Make sure to
run ``./autogen.sh && ./configure`` after merging this commit, or
incremental builds may fail. The automake integration is inspired
heavily by the protobuf project, and may still be problematic.
Make git ignore files generated by gtest compilation.
Currently putting in just one new-style unit test, refactoring old
tests to fit will come in separate commits.
Note: if you are starting daemons, listening on TCP ports, using
multiple machines, mounting filesystems, etc, it's not a unit test
and does not belong in this setup. A framework for system/integration
tests will be provided later.
2011-01-07 21:15:40 +00:00
|
|
|
AC_CONFIG_SUBDIRS([src/gtest])
|
2008-03-05 20:28:22 +00:00
|
|
|
|
|
|
|
# Environment
|
|
|
|
AC_CANONICAL_HOST
|
|
|
|
AC_CANONICAL_TARGET
|
|
|
|
|
2014-01-07 05:24:50 +00:00
|
|
|
# Fix automake problems in 1.12
|
|
|
|
m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
|
|
|
|
|
2008-03-05 20:28:22 +00:00
|
|
|
# Automake
|
2011-02-24 15:41:23 +00:00
|
|
|
AM_INIT_AUTOMAKE
|
2008-03-22 18:38:08 +00:00
|
|
|
AM_PROG_CC_C_O
|
2009-05-12 04:06:14 +00:00
|
|
|
AM_PROG_LIBTOOL
|
2013-08-21 04:56:34 +00:00
|
|
|
AM_PROG_AS
|
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
|
2011-11-09 05:13:07 +00:00
|
|
|
# enable make V=0 (if automake >1.11)
|
|
|
|
AM_INIT_AUTOMAKE([foreign])
|
|
|
|
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
|
|
|
|
|
2008-03-05 20:28:22 +00:00
|
|
|
# Platform
|
|
|
|
case "${target_os}" in
|
|
|
|
darwin*)
|
|
|
|
AC_DEFINE([DARWIN], [1], [Define if darwin/osx])
|
2014-10-29 08:48:07 +00:00
|
|
|
darwin="yes"
|
2011-09-22 03:59:58 +00:00
|
|
|
;;
|
|
|
|
linux*)
|
|
|
|
linux="yes"
|
|
|
|
;;
|
|
|
|
freebsd*)
|
|
|
|
freebsd="yes"
|
|
|
|
;;
|
2008-03-05 20:28:22 +00:00
|
|
|
esac
|
2011-09-22 03:59:58 +00:00
|
|
|
AM_CONDITIONAL(LINUX, test x"$linux" = x"yes")
|
|
|
|
AM_CONDITIONAL(FREEBSD, test x"$freebsd" = x"yes")
|
2014-10-29 08:48:07 +00:00
|
|
|
AM_CONDITIONAL(DARWIN, test x"$darwin" = x"yes")
|
2008-03-05 20:28:22 +00:00
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
# Checks for programs.
|
|
|
|
AC_PROG_CXX
|
2013-02-11 06:21:52 +00:00
|
|
|
if test "$CXX" = no || test "$CXX:$GXX" = "g++:"; then
|
|
|
|
AC_MSG_ERROR([no C++ compiler found])
|
|
|
|
fi
|
|
|
|
|
2013-11-06 22:32:35 +00:00
|
|
|
AC_MSG_CHECKING([if compiler is clang])
|
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [[
|
|
|
|
#ifndef __clang__
|
|
|
|
#error "Not Clang"
|
|
|
|
#endif
|
|
|
|
return 0;
|
|
|
|
]])],
|
|
|
|
[CLANG=yes], [CLANG=no])
|
|
|
|
AC_MSG_RESULT([$CLANG])
|
|
|
|
AM_CONDITIONAL(CLANG, test "$CLANG" = "yes")
|
2013-08-20 09:37:51 +00:00
|
|
|
|
2008-03-22 18:38:08 +00:00
|
|
|
#AC_PROG_CC
|
2008-01-28 19:05:29 +00:00
|
|
|
AC_PROG_MAKE_SET
|
2009-05-12 04:06:14 +00:00
|
|
|
AC_PROG_LIBTOOL
|
2008-01-28 19:05:29 +00:00
|
|
|
|
2012-11-06 06:30:29 +00:00
|
|
|
# Compiler flags
|
|
|
|
|
|
|
|
AC_SUBST(AM_CXXFLAGS)
|
|
|
|
AM_CXXFLAGS="${AM_CXXFLAGS}"
|
|
|
|
|
2013-08-21 04:56:34 +00:00
|
|
|
# Check for yasm
|
|
|
|
if yasm -f elf64 src/common/crc32c_intel_fast_asm.S -o /dev/null; then
|
|
|
|
echo 'we have a modern and working yasm'
|
2014-09-08 22:51:58 +00:00
|
|
|
if test `arch` = "x86_64" ; then
|
2013-08-21 04:56:34 +00:00
|
|
|
echo 'we are x86_64'
|
2014-09-08 22:51:58 +00:00
|
|
|
arch_x32=0
|
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [[
|
|
|
|
#if defined(__x86_64__) && defined(__ILP32__)
|
|
|
|
#error x32
|
|
|
|
#endif]])], [], [arch_x32=1])
|
|
|
|
if test $arch_x32 -eq 0 ; then
|
|
|
|
echo 'we are not x32'
|
|
|
|
AC_DEFINE([HAVE_GOOD_YASM_ELF64], [1], [we have a recent yasm and are x86_64])
|
|
|
|
with_good_yasm=yes
|
|
|
|
|
|
|
|
if yasm -f elf64 -i src/ceph/src/ceph/src/erasure-code/isa/isa-l/include/ src/erasure-code/isa/isa-l/erasure_code/gf_vect_dot_prod_avx2.asm.s -o /dev/null 2> /dev/null ; then
|
|
|
|
echo 'yasm can also build the isa-l stuff'
|
|
|
|
AC_DEFINE([HAVE_BETTER_YASM_ELF64], [1], [yasm can also build the isa-l])
|
|
|
|
with_better_yasm=yes
|
|
|
|
else
|
|
|
|
echo "yasm doesn't build the isa-l stuff"
|
|
|
|
fi
|
2014-07-31 22:18:51 +00:00
|
|
|
else
|
2014-09-08 22:51:58 +00:00
|
|
|
echo 'we are x32; no yasm for you'
|
2014-07-31 22:18:51 +00:00
|
|
|
fi
|
2014-09-08 22:51:58 +00:00
|
|
|
else
|
|
|
|
echo 'we are not x86_64 && !x32'
|
2013-08-21 04:56:34 +00:00
|
|
|
fi
|
|
|
|
else
|
|
|
|
echo 'we do not have a modern/working yasm'
|
|
|
|
fi
|
|
|
|
AM_CONDITIONAL(WITH_GOOD_YASM_ELF64, test "$with_good_yasm" = "yes")
|
2014-07-31 22:18:51 +00:00
|
|
|
AM_CONDITIONAL(WITH_BETTER_YASM_ELF64, test "$with_better_yasm" = "yes")
|
|
|
|
|
|
|
|
# check for better yasm
|
2013-08-21 04:56:34 +00:00
|
|
|
|
2011-04-26 22:06:46 +00:00
|
|
|
# Checks for compiler warning types
|
|
|
|
|
|
|
|
# AC_CHECK_CC_FLAG(FLAG_TO_TEST, VARIABLE_TO_SET_IF_SUPPORTED)
|
|
|
|
# ---------
|
|
|
|
AC_DEFUN([AC_CHECK_CC_FLAG],
|
|
|
|
[{
|
|
|
|
AC_LANG_PUSH([C])
|
|
|
|
my_cflags_save="$CFLAGS"
|
|
|
|
CFLAGS="$my_cflags_save $1"
|
|
|
|
AC_MSG_CHECKING([whether $CC accepts $1])
|
2012-03-16 17:39:39 +00:00
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[ ]])],
|
2011-04-26 22:06:46 +00:00
|
|
|
[AC_MSG_RESULT([yes]); AC_SUBST([$2], ["$1"])],
|
|
|
|
[AC_MSG_RESULT([no])]
|
|
|
|
)
|
|
|
|
CFLAGS="$my_cflags_save"
|
|
|
|
AC_LANG_POP([C])
|
|
|
|
}])
|
|
|
|
|
|
|
|
AC_CHECK_CC_FLAG([-Wtype-limits], [WARN_TYPE_LIMITS])
|
|
|
|
AC_CHECK_CC_FLAG([-Wignored-qualifiers], [WARN_IGNORED_QUALIFIERS])
|
|
|
|
|
2013-09-03 15:38:31 +00:00
|
|
|
# Checks for architecture stuff
|
|
|
|
AM_CONDITIONAL([ENABLE_FPU_NEON], [case $target_cpu in arm*) true;; *) false;; esac])
|
|
|
|
|
2013-09-07 11:14:05 +00:00
|
|
|
# Check for compiler VTA support
|
|
|
|
AX_CHECK_COMPILE_FLAG([-fvar-tracking-assignments], [HAS_VTA_SUPPORT=1], [HAS_VTA_SUPPORT=0])
|
|
|
|
AM_CONDITIONAL(COMPILER_HAS_VTA, [test "$HAS_VTA_SUPPORT" = 1])
|
|
|
|
|
2013-07-21 01:41:38 +00:00
|
|
|
AX_CXX_STATIC_CAST
|
assert: choose function-var name on non-gnu
Selects __PRETTY_FUNCTION__ or __func__. Linux assumes GNU, and chooses
__PRETTY_FUNCTION__ if gcc/g++ versions are favorable.
This also includes a fix in ax_c_var_func.m4:
AC_TRY_COMPILE will wrap the test in main{}, and then GCC will complain
about nested functions. Just use the original main{} body.
diff --git a/m4/ax_c_var_func.m4 b/m4/ax_c_var_func.m4
index 0ad7d2b..8b57563 100644
--- a/m4/ax_c_var_func.m4
+++ b/m4/ax_c_var_func.m4
@@ -57,9 +57,9 @@ AC_DEFUN([AX_C_VAR_FUNC],
[AC_REQUIRE([AC_PROG_CC])
AC_CACHE_CHECK(whether $CC recognizes __func__, ac_cv_c_var_func,
AC_TRY_COMPILE(,
-[int main() {
+[
char *s = __func__;
-}],
+],
AC_DEFINE(HAVE_FUNC,,
[Define if the C complier supports __func__]) ac_cv_c_var_func=yes,
ac_cv_c_var_func=no) )
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
2013-07-21 01:41:38 +00:00
|
|
|
AX_C_VAR_FUNC
|
|
|
|
AX_C_PRETTY_FUNC
|
2013-07-21 01:41:38 +00:00
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
# Checks for libraries.
|
2012-01-07 14:32:17 +00:00
|
|
|
ACX_PTHREAD
|
2013-12-13 15:40:52 +00:00
|
|
|
|
2011-11-12 00:38:35 +00:00
|
|
|
AC_CHECK_LIB([uuid], [uuid_parse], [true], AC_MSG_FAILURE([libuuid not found]))
|
2013-09-21 16:29:47 +00:00
|
|
|
|
2014-04-17 15:03:24 +00:00
|
|
|
# rbd {map,unmap,showmapped} dependencies, Linux only
|
2013-12-13 15:40:52 +00:00
|
|
|
if test x"$linux" = x"yes"; then
|
2014-04-17 15:03:24 +00:00
|
|
|
# libblkid
|
|
|
|
AC_CHECK_HEADER([blkid/blkid.h], [],
|
|
|
|
AC_MSG_ERROR([blkid/blkid.h not found (libblkid-dev, libblkid-devel)]))
|
2014-07-19 05:56:05 +00:00
|
|
|
AC_CHECK_LIB([blkid], [blkid_devno_to_wholedisk], [true],
|
2014-04-17 15:03:24 +00:00
|
|
|
AC_MSG_FAILURE([libblkid not found]))
|
2014-04-17 15:03:24 +00:00
|
|
|
|
|
|
|
# libudev
|
|
|
|
AC_CHECK_HEADER([libudev.h], [],
|
|
|
|
AC_MSG_ERROR([libudev.h not found (libudev-dev, libudev-devel)]))
|
2014-07-19 05:56:05 +00:00
|
|
|
AC_CHECK_LIB([udev], [udev_monitor_receive_device], [true],
|
2014-04-17 15:03:24 +00:00
|
|
|
AC_MSG_FAILURE([libudev not found]))
|
2013-12-13 15:40:52 +00:00
|
|
|
fi
|
|
|
|
|
2013-09-21 16:29:47 +00:00
|
|
|
#
|
|
|
|
# Check for res_nquery in libresolv. There are several variations. On OSX
|
|
|
|
# res_nquery is a macro defined in resolv.h, so the typical AC_CHECK_LIB
|
|
|
|
# doesn't work. On FreeBSD res_nquery can be found in libc. The required
|
|
|
|
# library for linking (if any) is defined RESOLV_LIBS.
|
|
|
|
#
|
|
|
|
AC_CHECK_HEADER([resolv.h], [], [], [#include <netinet/in.h>])
|
|
|
|
|
|
|
|
AC_DEFUN([CHECK_RESOLV_LIBS], [{
|
|
|
|
AC_MSG_CHECKING([if res_nquery will link (LIBS=$1)])
|
|
|
|
saved_LIBS="${LIBS}"
|
|
|
|
LIBS="$1"
|
|
|
|
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
|
|
|
|
#include <netinet/in.h>
|
|
|
|
#include <resolv.h>
|
|
|
|
]], [[res_nquery(0, 0, 0, 0, 0, 0);]])],
|
|
|
|
[AC_MSG_RESULT([yes])
|
|
|
|
[$2]],
|
|
|
|
AC_MSG_RESULT([no]))
|
|
|
|
LIBS="${saved_LIBS}"
|
|
|
|
}])
|
|
|
|
|
|
|
|
RESOLV_LIBS=""
|
|
|
|
CHECK_RESOLV_LIBS([$RESOLV_LIBS], [resolv_libs="ok"])
|
|
|
|
if test x"$resolv_libs" != "xok"; then
|
|
|
|
RESOLV_LIBS="-lresolv"
|
|
|
|
CHECK_RESOLV_LIBS([$RESOLV_LIBS], [resolv_libs="ok"])
|
|
|
|
if test x"$resolv_libs" != "xok"; then
|
|
|
|
AC_MSG_FAILURE([no resolv library found])
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
AC_SUBST([RESOLV_LIBS])
|
|
|
|
|
2013-09-21 19:50:28 +00:00
|
|
|
dnl check for libkeyutils on linux
|
|
|
|
KEYUTILS_LIB=""
|
|
|
|
AS_IF([test x"$linux" = x"yes"], [
|
|
|
|
AC_CHECK_LIB([keyutils], [add_key], [KEYUTILS_LIB="-lkeyutils"], [
|
|
|
|
AC_MSG_FAILURE([libkeyutils not found])])])
|
|
|
|
AC_SUBST(KEYUTILS_LIB)
|
|
|
|
|
2009-10-28 21:47:08 +00:00
|
|
|
AC_CHECK_LIB([m], [pow], [true], AC_MSG_FAILURE([libm not found]))
|
2011-04-13 20:28:52 +00:00
|
|
|
AC_CHECK_FUNCS([syncfs], AC_DEFINE([HAVE_SYS_SYNCFS], [1], [we have syncfs]), [])
|
2011-03-11 18:28:58 +00:00
|
|
|
|
|
|
|
# Find some crypto library for us to use, while letting user to decide which one to use.
|
|
|
|
AC_ARG_WITH([cryptopp],
|
|
|
|
[AS_HELP_STRING([--with-cryptopp], [Use cryptographic functions from cryptopp])],
|
|
|
|
[],
|
|
|
|
[with_cryptopp=check])
|
|
|
|
have_cryptopp=no
|
|
|
|
# this looks clumsy but it's just if A then { success } else { if B then success }
|
|
|
|
AS_IF([test "x$with_cryptopp" != "xno"],
|
|
|
|
[PKG_CHECK_MODULES([CRYPTOPP],
|
|
|
|
[libcrypto++],
|
|
|
|
[have_cryptopp=yes],
|
2012-01-07 15:02:45 +00:00
|
|
|
[
|
|
|
|
AC_LANG_PUSH([C++])
|
|
|
|
SAVED_CXXFLAGS="${CXXFLAGS}"
|
|
|
|
SAVED_LIBS="${LIBS}"
|
|
|
|
LIBS="${LIBS} ${PTHREAD_LIBS}"
|
|
|
|
CXXFLAGS="${CXXFLAGS} ${PTHREAD_CFLAGS}"
|
|
|
|
AC_SEARCH_LIBS([_ZTIN8CryptoPP14CBC_EncryptionE], [crypto++ cryptopp],
|
|
|
|
[have_cryptopp=yes],
|
|
|
|
[true], [])
|
|
|
|
CRYPTOPP_LIBS="${ac_cv_search__ZTIN8CryptoPP14CBC_EncryptionE}"
|
|
|
|
LIBS="${SAVED_LIBS}"
|
|
|
|
CXXFLAGS="${SAVED_CXXFLAGS}"
|
|
|
|
AC_LANG_POP([C++])
|
|
|
|
])])
|
2011-03-11 18:28:58 +00:00
|
|
|
# bail out if given explicit --with-cryptopp
|
|
|
|
if test "x$have_cryptopp" = "xno" -a "x$with_cryptopp" != "xcheck" -a "x$with_cryptopp" != "xno"; then
|
|
|
|
AC_MSG_FAILURE([--with-cryptopp was given, but library was not found])
|
|
|
|
fi
|
|
|
|
|
|
|
|
AC_ARG_WITH([nss],
|
|
|
|
[AS_HELP_STRING([--with-nss], [Use cryptographic functions from nss])],
|
|
|
|
[],
|
|
|
|
[with_nss=check])
|
|
|
|
have_nss=no
|
|
|
|
AS_IF([test "x$with_nss" != "xno"],
|
|
|
|
[PKG_CHECK_MODULES([NSS], [nss], [have_nss=yes], [true])])
|
|
|
|
# bail out if given explicit --with-nss
|
|
|
|
if test "x$have_nss" = "xno" -a "x$with_nss" != "xcheck" -a "x$with_nss" != "xno"; then
|
|
|
|
AC_MSG_FAILURE([--with-nss was given, but library was not found])
|
|
|
|
fi
|
|
|
|
|
|
|
|
# now decide which crypto library to really use
|
|
|
|
if test "x$have_cryptopp" = "xyes"; then
|
|
|
|
AC_MSG_NOTICE([using cryptopp for cryptography])
|
|
|
|
AC_DEFINE([USE_CRYPTOPP], [1], [Define if using CryptoPP.])
|
|
|
|
AC_SUBST([CRYPTO_CFLAGS], [$CRYPTOPP_CFLAGS])
|
2012-11-06 06:30:29 +00:00
|
|
|
#AC_SUBST([CRYPTO_CXXFLAGS], [$CRYPTOPP_CXXFLAGS])
|
|
|
|
AM_CXXFLAGS="${AM_CXXFLAGS} ${CRYPTOPP_CXXFLAGS}"
|
2011-03-11 18:28:58 +00:00
|
|
|
AC_SUBST([CRYPTO_LIBS], [$CRYPTOPP_LIBS])
|
|
|
|
elif test "x$have_nss" = "xyes"; then
|
|
|
|
AC_MSG_NOTICE([using nss for cryptography])
|
|
|
|
AC_DEFINE([USE_NSS], [1], [Define if using NSS.])
|
|
|
|
AC_SUBST([CRYPTO_CFLAGS], [$NSS_CFLAGS])
|
|
|
|
# this needs CFLAGS too in practise to get the includes right. ugly.
|
2012-11-06 06:30:29 +00:00
|
|
|
#AC_SUBST([CRYPTO_CXXFLAGS], [$NSS_CFLAGS $NSS_CXXFLAGS])
|
|
|
|
AM_CXXFLAGS="${AM_CXXFLAGS} ${NSS_CFLAGS} ${NSS_CXXFLAGS}"
|
2011-03-11 18:28:58 +00:00
|
|
|
AC_SUBST([CRYPTO_LIBS], [$NSS_LIBS])
|
|
|
|
else
|
|
|
|
AC_MSG_FAILURE([no suitable crypto library found])
|
|
|
|
fi
|
2008-01-28 19:05:29 +00:00
|
|
|
|
2011-02-24 14:00:27 +00:00
|
|
|
# profiler?
|
|
|
|
AC_ARG_WITH([profiler],
|
|
|
|
[AS_HELP_STRING([--with-profiler], [build extra profiler binaries])],
|
2011-03-11 22:08:15 +00:00
|
|
|
[case "${withval}" in
|
|
|
|
yes) with_profiler=yes ;;
|
|
|
|
no) with_profiler=no ;;
|
|
|
|
*) AC_MSG_ERROR([bad value ${withval} for --with-profiler]) ;;
|
|
|
|
esac],
|
2011-02-24 14:00:27 +00:00
|
|
|
[with_profiler=no])
|
2011-03-03 19:56:43 +00:00
|
|
|
AS_IF([test "x$with_profiler" = xyes],
|
2011-02-24 14:00:27 +00:00
|
|
|
[AC_CHECK_LIB([profiler], [ProfilerFlush], [],
|
|
|
|
[AC_MSG_FAILURE([--with-profiler was given but libprofiler (libgoogle-perftools-dev on debian) not found])])],
|
|
|
|
[])
|
|
|
|
AM_CONDITIONAL(WITH_PROFILER, test "$with_profiler" = "yes")
|
|
|
|
AS_IF([test "$with_profiler" = "yes"],
|
|
|
|
[AC_DEFINE([HAVE_PROFILER], [1], [Define if you have perftools profiler enabled])],
|
|
|
|
[])
|
|
|
|
|
2008-07-11 00:12:34 +00:00
|
|
|
# debug crap?
|
|
|
|
AC_ARG_WITH([debug],
|
|
|
|
[AS_HELP_STRING([--with-debug], [build extra debug binaries])],
|
2011-03-11 22:11:54 +00:00
|
|
|
[case "${withval}" in
|
|
|
|
yes) with_debug=yes ;;
|
|
|
|
no) with_debug=no ;;
|
|
|
|
*) AC_MSG_ERROR([bad value ${withval} for --with-debug]) ;;
|
|
|
|
esac],
|
2008-07-11 04:21:37 +00:00
|
|
|
[with_debug=no])
|
2008-10-31 18:52:25 +00:00
|
|
|
AM_CONDITIONAL(WITH_DEBUG, test "$with_debug" = "yes")
|
2008-07-11 00:12:34 +00:00
|
|
|
|
2011-01-15 00:12:32 +00:00
|
|
|
AC_DEFINE([DEBUG_GATHER], [1], [Define if you want C_Gather debugging])
|
|
|
|
|
2014-10-07 19:18:00 +00:00
|
|
|
AC_ARG_ENABLE([docker],
|
|
|
|
[AS_HELP_STRING([--enable-docker], [enable docker based functional tests])],
|
|
|
|
[],
|
|
|
|
[enable_docker=no])
|
|
|
|
AM_CONDITIONAL(ENABLE_DOCKER, test "x$enable_docker" != xno)
|
|
|
|
|
2011-05-28 00:37:43 +00:00
|
|
|
# code coverage?
|
|
|
|
AC_ARG_ENABLE([coverage],
|
|
|
|
[AS_HELP_STRING([--enable-coverage], [enable code coverage tracking])],
|
|
|
|
[],
|
|
|
|
[enable_coverage=no])
|
|
|
|
AM_CONDITIONAL(ENABLE_COVERAGE, test "x$enable_coverage" != xno)
|
2011-06-10 00:33:25 +00:00
|
|
|
if test "x$enable_coverage" != xno; then
|
|
|
|
AC_DEFINE([ENABLE_COVERAGE], [1], [Define if enabling coverage.])
|
|
|
|
fi
|
2011-06-07 17:06:58 +00:00
|
|
|
AC_SUBST(GCOV_PREFIX_STRIP, `echo $(pwd)/src | tr -dc / | wc -c`)
|
2011-05-28 00:37:43 +00:00
|
|
|
|
2009-08-13 18:23:54 +00:00
|
|
|
# radosgw?
|
|
|
|
AC_ARG_WITH([radosgw],
|
|
|
|
[AS_HELP_STRING([--with-radosgw], [build RADOS gateway])],
|
|
|
|
[],
|
|
|
|
[with_radosgw=check])
|
2010-07-09 20:43:42 +00:00
|
|
|
RADOSGW=0
|
2009-08-13 18:23:54 +00:00
|
|
|
AS_IF([test "x$with_radosgw" != xno],
|
2009-07-09 23:28:18 +00:00
|
|
|
[AC_CHECK_LIB([fcgi], [FCGX_Init],
|
2010-07-09 20:43:42 +00:00
|
|
|
[AC_CHECK_LIB([expat], [XML_Parse],
|
2011-02-23 19:27:58 +00:00
|
|
|
[AC_CHECK_LIB([curl], [curl_easy_init],
|
2011-10-09 22:27:10 +00:00
|
|
|
[RADOSGW=1
|
|
|
|
AC_CHECK_HEADER([fastcgi/fcgiapp.h],
|
|
|
|
[AC_DEFINE([FASTCGI_INCLUDE_DIR], [1], [FastCGI headers are in /usr/include/fastcgi])])
|
|
|
|
],
|
2011-02-23 19:27:58 +00:00
|
|
|
[if test "x$with_radosgw" != "xcheck"; then
|
|
|
|
AC_MSG_FAILURE([--with-radosgw was given but libcurl (libcurl-dev on debian) not found])
|
|
|
|
fi])
|
|
|
|
],
|
2010-07-09 20:43:42 +00:00
|
|
|
[if test "x$with_radosgw" != "xcheck"; then
|
|
|
|
AC_MSG_FAILURE([--with-radosgw was given but libexpat (libexpat1-dev on debian) not found])
|
|
|
|
fi])
|
|
|
|
],
|
|
|
|
[if test "x$with_radosgw" != "xcheck"; then
|
2009-09-25 16:06:30 +00:00
|
|
|
AC_MSG_FAILURE([--with-radosgw was given but libfcgi (libfcgi-dev on debian) not found])
|
2009-09-25 15:43:03 +00:00
|
|
|
fi])])
|
2009-08-20 23:02:46 +00:00
|
|
|
AM_CONDITIONAL(WITH_RADOSGW, test "$RADOSGW" = "1")
|
2009-07-09 23:28:18 +00:00
|
|
|
|
2012-03-14 00:03:09 +00:00
|
|
|
AS_IF([test "$RADOSGW" = "1"], [AC_DEFINE([WITH_RADOSGW], [1], [define if radosgw enabled])])
|
|
|
|
|
2014-05-06 14:04:56 +00:00
|
|
|
AS_IF([test "$RADOSGW" = "1"],
|
2013-07-09 01:54:23 +00:00
|
|
|
[AC_CHECK_LIB([curl], [curl_multi_wait],
|
|
|
|
AC_DEFINE([HAVE_CURL_MULTI_WAIT], [1], [Define if have curl_multi_wait()]))
|
|
|
|
])
|
|
|
|
|
2008-01-28 19:05:29 +00:00
|
|
|
# fuse?
|
|
|
|
AC_ARG_WITH([fuse],
|
2011-03-11 20:39:22 +00:00
|
|
|
[AS_HELP_STRING([--without-fuse], [disable FUSE userspace client])],
|
2008-01-28 19:05:29 +00:00
|
|
|
[],
|
2011-03-11 20:39:22 +00:00
|
|
|
[with_fuse=yes])
|
2008-01-28 19:05:29 +00:00
|
|
|
LIBFUSE=
|
|
|
|
AS_IF([test "x$with_fuse" != xno],
|
|
|
|
[AC_CHECK_LIB([fuse], [fuse_main],
|
|
|
|
[AC_SUBST([LIBFUSE], ["-lfuse"])
|
|
|
|
AC_DEFINE([HAVE_LIBFUSE], [1],
|
|
|
|
[Define if you have fuse])
|
|
|
|
HAVE_LIBFUSE=1
|
2013-01-28 15:33:42 +00:00
|
|
|
# look for fuse_getgroups and define FUSE_GETGROUPS if found
|
2013-07-20 18:10:24 +00:00
|
|
|
LIBS_saved="$LIBS"
|
|
|
|
LIBS="$LIBS -lfuse"
|
2013-01-28 15:33:42 +00:00
|
|
|
AC_CHECK_FUNCS([fuse_getgroups])
|
2013-07-20 18:10:24 +00:00
|
|
|
LIBS="$LIBS_saved"
|
2008-01-28 19:05:29 +00:00
|
|
|
],
|
2011-03-11 20:39:22 +00:00
|
|
|
[AC_MSG_FAILURE(
|
|
|
|
[no FUSE found (use --without-fuse to disable)])])])
|
2008-01-28 19:05:29 +00:00
|
|
|
AM_CONDITIONAL(WITH_FUSE, [test "$HAVE_LIBFUSE" = "1"])
|
|
|
|
|
2010-08-06 21:47:06 +00:00
|
|
|
# tcmalloc?
|
|
|
|
AC_ARG_WITH([tcmalloc],
|
2011-04-19 19:05:36 +00:00
|
|
|
[AS_HELP_STRING([--without-tcmalloc], [disable tcmalloc for memory allocations])],
|
2010-08-06 21:47:06 +00:00
|
|
|
[],
|
2011-04-19 19:05:36 +00:00
|
|
|
[with_tcmalloc=yes])
|
2010-08-06 21:47:06 +00:00
|
|
|
TCMALLOC=
|
|
|
|
AS_IF([test "x$with_tcmalloc" != xno],
|
|
|
|
[AC_CHECK_LIB([tcmalloc], [malloc],
|
|
|
|
[AC_SUBST([LIBTCMALLOC], ["-ltcmalloc"])
|
|
|
|
AC_DEFINE([HAVE_LIBTCMALLOC], [1],
|
|
|
|
[Define if you have tcmalloc])
|
|
|
|
HAVE_LIBTCMALLOC=1
|
|
|
|
],
|
2011-04-19 19:05:36 +00:00
|
|
|
[AC_MSG_FAILURE(
|
|
|
|
[no tcmalloc found (use --without-tcmalloc to disable)])])])
|
2010-08-06 21:47:06 +00:00
|
|
|
AM_CONDITIONAL(WITH_TCMALLOC, [test "$HAVE_LIBTCMALLOC" = "1"])
|
|
|
|
|
2013-04-19 00:54:39 +00:00
|
|
|
#set pg ref debugging?
|
|
|
|
AC_ARG_ENABLE([pgrefdebugging],
|
|
|
|
[AS_HELP_STRING([--enable-pgrefdebugging], [enable pg ref debugging])],
|
|
|
|
[AC_DEFINE([PG_DEBUG_REFS], [1], [Defined if you want pg ref debugging])],
|
|
|
|
[])
|
|
|
|
|
2012-09-01 17:26:41 +00:00
|
|
|
#
|
|
|
|
# Java is painful
|
|
|
|
# - adapted from OMPI wrappers package
|
|
|
|
# - this might become bigger. maybe should be own m4 file
|
|
|
|
#
|
|
|
|
AC_ARG_ENABLE(cephfs-java,
|
2013-01-16 12:40:17 +00:00
|
|
|
[AC_HELP_STRING([--enable-cephfs-java], [build libcephfs Java bindings])],
|
2012-09-01 17:26:41 +00:00
|
|
|
[], [enable_cephfs_java=no])
|
|
|
|
|
2013-01-16 12:40:17 +00:00
|
|
|
AM_CONDITIONAL(ENABLE_CEPHFS_JAVA, [test "x$enable_cephfs_java" = "xyes"])
|
2012-09-01 17:26:41 +00:00
|
|
|
|
|
|
|
AC_ARG_WITH(jdk-dir,
|
|
|
|
AC_HELP_STRING([--with-jdk-dir(=DIR)], [Path to JDK directory]))
|
|
|
|
|
2013-01-16 12:40:17 +00:00
|
|
|
if test "x$enable_cephfs_java" = "xyes"; then
|
2012-09-01 17:26:41 +00:00
|
|
|
|
|
|
|
# setup bin/include dirs from --with-jdk-dir (search for jni.h, javac)
|
|
|
|
AS_IF([test -n "$with_jdk_dir"], [
|
|
|
|
javac_prog=`find $with_jdk_dir/ -name javac | head -n 1`
|
|
|
|
AS_IF([test -x "$javac_prog"], [
|
|
|
|
EXTRA_JDK_BIN_DIR=`dirname $javac_prog`])
|
|
|
|
jnih=`find $with_jdk_dir/ -name jni.h | head -n 1`
|
|
|
|
AS_IF([test -r "$jnih"], [
|
|
|
|
EXTRA_JDK_INC_DIR=`dirname $jnih`])])
|
|
|
|
|
|
|
|
# setup defaults for Debian default-jdk package (without --with-jdk-dir)
|
|
|
|
AS_IF([test -z "$with_jdk_dir"], [
|
2013-09-12 20:14:28 +00:00
|
|
|
# This works with Debian's and CentOS' default-jdk package
|
2014-05-12 03:57:20 +00:00
|
|
|
for dir in '/usr/lib/jvm/default-java/' '/usr/lib/jvm/java/' '/usr/lib/jvm/java-gcj/'; do
|
2013-09-12 20:14:28 +00:00
|
|
|
# only test if a suitable path has not yet been found
|
|
|
|
AS_IF([test "$EXTRA_JDK_BIN_DIR" == ""], [
|
|
|
|
AS_IF([test -x "$javac_prog"], [
|
|
|
|
EXTRA_JDK_BIN_DIR=`dirname $javac_prog`])
|
|
|
|
jnih=`find $dir -name jni.h | head -n 1`
|
|
|
|
AS_IF([test -r "$jnih"], [
|
|
|
|
EXTRA_JDK_INC_DIR=`dirname $jnih`])
|
|
|
|
])
|
|
|
|
done
|
|
|
|
])
|
2012-09-01 17:26:41 +00:00
|
|
|
|
2013-01-16 12:40:17 +00:00
|
|
|
# cephfs_java_test only makes sense if java is already turned on
|
2014-05-06 14:04:56 +00:00
|
|
|
# setup CLASSPATH for Debian default junit4.jar package
|
2013-01-16 12:40:17 +00:00
|
|
|
#
|
|
|
|
# Configuring --with-debug and --enable-cephfs-java will throw an error if
|
|
|
|
# JUnit4 cannot be found. While currently this works for users who have
|
|
|
|
# installed via the package manager on Ubuntu, we need to expand this
|
|
|
|
# check to 1 support other distrubtions and 2 allow users to influence
|
|
|
|
# the search path.
|
|
|
|
AS_IF([test "x$with_debug" = "xyes"], [
|
|
|
|
dir='/usr/share/java'
|
|
|
|
junit4_jar=`find $dir -name junit4.jar | head -n 1`
|
|
|
|
AS_IF([test -r "$junit4_jar"], [
|
|
|
|
EXTRA_CLASSPATH_JAR=`dirname $junit4_jar`/junit4.jar
|
|
|
|
AC_SUBST(EXTRA_CLASSPATH_JAR)
|
|
|
|
[have_junit4=1]], [
|
|
|
|
AC_MSG_NOTICE([Cannot find junit4.jar (apt-get install junit4)])
|
|
|
|
[have_junit4=0]])])
|
|
|
|
|
|
|
|
AC_CHECK_CLASSPATH
|
|
|
|
AC_PROG_JAVAC
|
|
|
|
AC_PROG_JAVAH
|
|
|
|
AC_PROG_JAR
|
|
|
|
|
|
|
|
CLASSPATH=$CLASSPATH:$EXTRA_CLASSPATH_JAR
|
|
|
|
export CLASSPATH
|
|
|
|
AC_MSG_NOTICE([classpath - $CLASSPATH])
|
2012-09-01 17:26:41 +00:00
|
|
|
|
2013-01-09 21:35:16 +00:00
|
|
|
# Check for jni.h
|
2012-09-01 17:26:41 +00:00
|
|
|
CPPFLAGS_save=$CPPFLAGS
|
|
|
|
|
|
|
|
AS_IF([test -n "$EXTRA_JDK_INC_DIR"],
|
|
|
|
[JDK_CPPFLAGS="-I$EXTRA_JDK_INC_DIR"
|
|
|
|
AS_IF([test -d "$EXTRA_JDK_INC_DIR/linux"],
|
|
|
|
[JDK_CPPFLAGS="$JDK_CPPFLAGS -I$EXTRA_JDK_INC_DIR/linux"])
|
|
|
|
CPPFLAGS="$CPPFLAGS $JDK_CPPFLAGS"])
|
|
|
|
|
2013-01-09 21:35:16 +00:00
|
|
|
AC_CHECK_HEADER([jni.h], [], AC_MSG_ERROR([Cannot find header 'jni.h'. Try setting --with-jdk-dir]))
|
2012-09-01 17:26:41 +00:00
|
|
|
|
|
|
|
CPPFLAGS=$CPPFLAGS_save
|
|
|
|
|
|
|
|
# Setup output var
|
|
|
|
AC_SUBST(JDK_CPPFLAGS)
|
2013-01-16 12:40:17 +00:00
|
|
|
fi
|
2013-01-04 17:51:31 +00:00
|
|
|
AM_CONDITIONAL(HAVE_JUNIT4, [test "$have_junit4" = "1"])
|
2012-09-01 17:26:41 +00:00
|
|
|
|
2011-09-22 03:59:58 +00:00
|
|
|
#
|
|
|
|
# FreeBSD has it in base.
|
|
|
|
#
|
|
|
|
if test x"$freebsd" != x"yes"; then
|
2011-01-18 10:51:32 +00:00
|
|
|
PKG_CHECK_MODULES([LIBEDIT], [libedit >= 2.11],
|
|
|
|
[], AC_MSG_FAILURE([No usable version of libedit found.]))
|
2011-10-05 02:03:55 +00:00
|
|
|
else
|
|
|
|
LIBEDIT_LIBS="-ledit"
|
2011-09-22 03:59:58 +00:00
|
|
|
fi
|
2011-01-18 10:51:32 +00:00
|
|
|
|
2010-04-14 23:51:40 +00:00
|
|
|
#libatomic-ops? You want it!
|
|
|
|
AC_ARG_WITH([libatomic-ops],
|
2011-03-11 21:07:31 +00:00
|
|
|
[AS_HELP_STRING([--without-libatomic-ops],
|
|
|
|
[disable libatomic-ops for the atomic_t type])],
|
2008-01-28 19:05:29 +00:00
|
|
|
[],
|
2011-03-11 21:07:31 +00:00
|
|
|
[with_libatomic_ops=yes])
|
2010-04-14 23:51:40 +00:00
|
|
|
AS_IF([test "x$with_libatomic_ops" != xno],
|
|
|
|
[AC_CHECK_HEADER([atomic_ops.h],
|
|
|
|
[HAVE_ATOMIC_OPS=1],
|
2011-03-11 21:07:31 +00:00
|
|
|
[AC_MSG_FAILURE(
|
|
|
|
[no libatomic-ops found (use --without-libatomic-ops to disable)])
|
|
|
|
])])
|
2010-04-14 23:51:40 +00:00
|
|
|
AS_IF([test "$HAVE_ATOMIC_OPS" = "1"],
|
2014-03-31 21:49:50 +00:00
|
|
|
[
|
|
|
|
AC_CHECK_SIZEOF(AO_t, [], [
|
|
|
|
#include <atomic_ops.h>
|
|
|
|
])
|
|
|
|
],
|
2013-01-28 15:33:42 +00:00
|
|
|
[AC_DEFINE([NO_ATOMIC_OPS], [1], [Defined if you do not have atomic_ops])])
|
|
|
|
|
2014-03-31 21:49:50 +00:00
|
|
|
|
2010-04-14 23:51:40 +00:00
|
|
|
AM_CONDITIONAL(WITH_LIBATOMIC, [test "$HAVE_ATOMIC_OPS" = "1"])
|
2008-01-28 19:05:29 +00:00
|
|
|
|
|
|
|
# newsyn? requires mpi.
|
2008-01-28 19:39:51 +00:00
|
|
|
#AC_ARG_WITH([newsyn],
|
2009-09-25 16:07:58 +00:00
|
|
|
# [AS_HELP_STRING([--with-newsyn], [build newsyn target requires mpi])],
|
2008-01-28 19:39:51 +00:00
|
|
|
# [],
|
|
|
|
# [with_newsyn=no])
|
2008-01-28 02:12:20 +00:00
|
|
|
|
2011-12-29 19:58:01 +00:00
|
|
|
AC_ARG_WITH([ocf],
|
|
|
|
[AS_HELP_STRING([--with-ocf], [build OCF-compliant cluster resource agent])],
|
|
|
|
,
|
|
|
|
[with_ocf=no])
|
|
|
|
AM_CONDITIONAL(WITH_OCF, [ test "$with_ocf" = "yes" ])
|
|
|
|
|
2013-02-27 13:27:48 +00:00
|
|
|
# check is snappy-devel is installed, needed by leveldb
|
2014-07-18 04:44:06 +00:00
|
|
|
AC_CHECK_LIB([snappy], [snappy_compress], [true], [AC_MSG_FAILURE([libsnappy not found])])
|
2013-02-16 01:58:48 +00:00
|
|
|
# use system leveldb
|
2014-07-18 04:44:06 +00:00
|
|
|
AC_CHECK_LIB([leveldb], [leveldb_open], [true], [AC_MSG_FAILURE([libleveldb not found])], [-lsnappy -lpthread])
|
2013-04-17 20:21:04 +00:00
|
|
|
# see if we can use bloom filters with leveldb
|
|
|
|
AC_LANG_PUSH([C++])
|
|
|
|
AC_CHECK_HEADER([leveldb/filter_policy.h], [AC_DEFINE([HAVE_LEVELDB_FILTER_POLICY], [1], [Defined if LevelDB supports bloom filters ])])
|
|
|
|
AC_LANG_POP([C++])
|
2012-04-10 03:30:42 +00:00
|
|
|
|
2014-03-21 12:07:32 +00:00
|
|
|
# Find supported SIMD / SSE extensions supported by the compiler
|
2014-03-26 10:11:48 +00:00
|
|
|
AX_INTEL_FEATURES()
|
2014-03-06 15:35:50 +00:00
|
|
|
|
2014-05-29 19:23:30 +00:00
|
|
|
# kinetic osd backend?
|
|
|
|
AC_ARG_WITH([kinetic],
|
|
|
|
[AS_HELP_STRING([--with-kinetic], [build kinetic support])],
|
|
|
|
[],
|
|
|
|
[with_kinetic=no])
|
|
|
|
# no pkg-config support yet
|
|
|
|
#AS_IF([test "x$with_kinetic" = "xyes"],
|
|
|
|
# [PKG_CHECK_MODULES([KINETIC], [kinetic_client], [], [true])])
|
|
|
|
AS_IF([test "x$with_kinetic" = "xyes"],
|
|
|
|
[AC_DEFINE([HAVE_KINETIC], [1], [Defined if you have kinetic enabled])])
|
|
|
|
AM_CONDITIONAL(WITH_KINETIC, [ test "$with_kinetic" = "yes" ])
|
|
|
|
|
2014-07-29 00:03:06 +00:00
|
|
|
# check for c++11 (but do not enable it)
|
|
|
|
old_cxxflags="$CXXFLAGS"
|
|
|
|
AX_CXX_COMPILE_STDCXX_11([], [optional])
|
|
|
|
CXXFLAGS="$old_cxxflags"
|
|
|
|
|
2014-02-18 01:27:44 +00:00
|
|
|
# use rocksdb
|
|
|
|
AC_ARG_WITH([librocksdb],
|
|
|
|
[AS_HELP_STRING([--with-librocksdb], [build rocksdb support])],
|
|
|
|
[],
|
|
|
|
[with_librocksdb=no])
|
|
|
|
AS_IF([test "x$with_librocksdb" = "xyes"],
|
|
|
|
[PKG_CHECK_MODULES([LIBROCKSDB], [rocksdb], [], [true])])
|
|
|
|
AS_IF([test "x$with_librocksdb" = "xyes"],
|
2014-10-23 05:20:58 +00:00
|
|
|
[AC_CHECK_LIB([rocksdb], [open], [], [AC_MSG_FAILURE([librocksdb not found])])])
|
2014-05-28 02:11:37 +00:00
|
|
|
AM_CONDITIONAL(WITH_DLIBROCKSDB, [ test "$with_librocksdb" = "yes" ])
|
2014-02-18 01:27:44 +00:00
|
|
|
|
2014-05-28 02:11:37 +00:00
|
|
|
AC_ARG_WITH([librocksdb-static],
|
|
|
|
[AS_HELP_STRING([--with-librocksdb-static], [build rocksdb support])],
|
|
|
|
[],
|
|
|
|
[with_librocksdb_static=no])
|
2014-07-29 00:03:06 +00:00
|
|
|
AS_IF([test "x$with_librocksdb_static" = "xcheck" -a "x$HAVE_CXX11" = "x1" ],
|
|
|
|
[with_librocksdb_static="yes"])
|
2014-05-28 02:11:37 +00:00
|
|
|
AS_IF([test "x$with_librocksdb_static" = "xyes"],
|
|
|
|
[AC_CONFIG_SUBDIRS([src/rocksdb])])
|
|
|
|
AS_IF([test "x$with_librocksdb_static" = "xyes"],
|
|
|
|
[AC_DEFINE([HAVE_LIBROCKSDB], [1], [Defined if you have librocksdb enabled])])
|
2014-07-16 18:33:03 +00:00
|
|
|
AM_CONDITIONAL(WITH_SLIBROCKSDB, [ test "x$with_librocksdb_static" = "xyes" ])
|
|
|
|
AM_CONDITIONAL(WITH_LIBROCKSDB, [ test "x$with_librocksdb_static" = "xyes" -o "x$with_librocksdb" = "xyes" ])
|
2014-02-18 01:27:44 +00:00
|
|
|
|
2012-04-30 20:55:16 +00:00
|
|
|
# use system libs3?
|
|
|
|
AC_ARG_WITH([system-libs3],
|
|
|
|
[AS_HELP_STRING([--with-system-libs3], [use system libs3])],
|
|
|
|
,
|
|
|
|
[with_system_libs3=no])
|
|
|
|
AS_IF([test "x$with_system_libs3" = xyes],
|
|
|
|
[AC_CHECK_LIB([s3], [S3_initialize], [true], [AC_MSG_FAILURE([libs3 not found])], [-lpthread])])
|
|
|
|
AS_IF([test "x$with_system_libs3" = xcheck],
|
|
|
|
[AC_SEARCH_LIBS([S3_initialize], [s3], [with_system_libs3=yes], [true], [-lpthread])])
|
|
|
|
AM_CONDITIONAL(WITH_SYSTEM_LIBS3, [ test "$with_system_libs3" = "yes" ])
|
|
|
|
|
|
|
|
# rest-bench?
|
|
|
|
AC_ARG_WITH([rest-bench],
|
|
|
|
[AS_HELP_STRING([--with-rest-bench], [enables rest-bench])],
|
|
|
|
[],
|
|
|
|
[with_rest_bench=no])
|
|
|
|
AM_CONDITIONAL(WITH_REST_BENCH, [ test "$with_rest_bench" = "yes" ])
|
|
|
|
|
2012-01-31 00:48:26 +00:00
|
|
|
# use libaio?
|
|
|
|
AC_ARG_WITH([libaio],
|
|
|
|
[AS_HELP_STRING([--without-libaio], [disable libaio use by journal])],
|
|
|
|
,
|
|
|
|
[with_libaio=yes])
|
|
|
|
AS_IF([test "x$with_libaio" != xno],
|
|
|
|
[AC_CHECK_LIB([aio], [io_submit], [true], AC_MSG_FAILURE([libaio not found]))])
|
|
|
|
AS_IF([test "x$with_libaio" != xno],
|
2014-05-06 14:04:56 +00:00
|
|
|
[AC_CHECK_HEADER([libaio.h])])
|
2012-01-31 00:48:26 +00:00
|
|
|
AS_IF([test "$with_libaio" = "yes"],
|
|
|
|
[AC_DEFINE([HAVE_LIBAIO], [1], [Defined if you don't have atomic_ops])])
|
|
|
|
AM_CONDITIONAL(WITH_LIBAIO, [ test "$with_libaio" = "yes" ])
|
|
|
|
|
2014-03-10 08:36:48 +00:00
|
|
|
# use libxfs?
|
|
|
|
AC_ARG_WITH([libxfs],
|
|
|
|
[AS_HELP_STRING([--without-libxfs], [disable libxfs use by FileStore])],
|
|
|
|
[],
|
|
|
|
[with_libxfs=yes])
|
|
|
|
AS_IF([test "x$with_libxfs" != "xno"], [
|
|
|
|
# xfs/xfs.h presence and XFS_XFLAG_EXTSIZE define
|
|
|
|
AC_CHECK_HEADER([xfs/xfs.h], [], AC_MSG_ERROR(
|
|
|
|
[xfs/xfs.h not found (--without-libxfs to disable)]))
|
|
|
|
AC_MSG_CHECKING([for XFS_XFLAG_EXTSIZE in xfs/xfs.h])
|
|
|
|
AC_EGREP_CPP([yes_have_xfs_xflag_extsize], [
|
|
|
|
#include <xfs/xfs.h>
|
|
|
|
#ifdef XFS_XFLAG_EXTSIZE
|
|
|
|
yes_have_xfs_xflag_extsize
|
|
|
|
#endif
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([yes])
|
|
|
|
AC_DEFINE([HAVE_LIBXFS], [1], [Define to 1 if you have libxfs])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([no])
|
|
|
|
AC_MSG_ERROR([XFS_XFLAG_EXTSIZE not found (--without-libxfs to disable)])
|
|
|
|
])
|
|
|
|
])
|
|
|
|
AM_CONDITIONAL(WITH_LIBXFS, [test "x$with_libxfs" != "xno"])
|
|
|
|
|
2013-08-07 06:38:22 +00:00
|
|
|
# use libzfs
|
|
|
|
AC_ARG_WITH([libzfs],
|
|
|
|
[AS_HELP_STRING([--with-libzfs], [build ZFS support])],
|
|
|
|
,
|
|
|
|
[with_libzfs=no])
|
|
|
|
AS_IF([test "x$with_libzfs" = xyes],
|
|
|
|
[PKG_CHECK_MODULES([LIBZFS], [zfs], [], [true])])
|
|
|
|
AS_IF([test "x$with_libzfs" = xyes],
|
|
|
|
[AC_DEFINE([HAVE_LIBZFS], [1], [Defined if you have libzfs enabled])])
|
|
|
|
AM_CONDITIONAL(WITH_LIBZFS, [ test "$with_libzfs" = "yes" ])
|
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
# Checks for header files.
|
|
|
|
AC_HEADER_DIRENT
|
|
|
|
AC_HEADER_STDC
|
|
|
|
AC_HEADER_SYS_WAIT
|
2008-04-09 21:39:25 +00:00
|
|
|
|
2012-01-28 19:08:37 +00:00
|
|
|
|
2008-04-09 21:39:25 +00:00
|
|
|
# spirit?
|
|
|
|
AC_LANG([C++])
|
2011-01-24 00:09:14 +00:00
|
|
|
|
|
|
|
AC_CHECK_HEADER([boost/spirit/include/classic_core.hpp], [],
|
|
|
|
[AC_CHECK_HEADER([boost/spirit.hpp], [use_bspirit_old_hdr=yes],
|
|
|
|
AC_MSG_FAILURE(["Can't find boost spirit headers"]))])
|
|
|
|
AM_CONDITIONAL(USE_BOOST_SPIRIT_OLD_HDR, [test "$use_bspirit_old_hdr" = "yes"])
|
2008-04-09 21:39:25 +00:00
|
|
|
|
2012-06-03 23:12:20 +00:00
|
|
|
AC_CHECK_HEADER([boost/random/discrete_distribution.hpp],
|
2012-10-09 19:47:22 +00:00
|
|
|
[AC_DEFINE([HAVE_BOOST_RANDOM_DISCRETE_DISTRIBUTION], [], [have boost::random::discrete_distribution])],
|
2012-06-03 23:12:20 +00:00
|
|
|
[])
|
|
|
|
|
2011-06-14 04:56:47 +00:00
|
|
|
AC_CHECK_HEADER([boost/statechart/state.hpp], [],
|
|
|
|
AC_MSG_FAILURE(["Can't find boost statechart headers; need 1.34 or later"]))
|
2012-10-31 17:27:33 +00:00
|
|
|
AC_CHECK_HEADER([boost/program_options/option.hpp], [],
|
|
|
|
AC_MSG_FAILURE(["Can't find boost program_options headers"]))
|
2011-06-14 04:56:47 +00:00
|
|
|
|
2012-10-09 02:18:56 +00:00
|
|
|
# If we have the boost system library installed, then we may want to link
|
|
|
|
# with it.
|
2012-10-08 17:04:25 +00:00
|
|
|
AC_CHECK_LIB(boost_system-mt, main, [],
|
2012-10-09 05:56:05 +00:00
|
|
|
[AC_CHECK_LIB(boost_system, main, [],
|
|
|
|
AC_MSG_NOTICE(["Boost system library not found."]))])
|
2012-10-08 17:04:25 +00:00
|
|
|
|
2012-11-16 08:46:41 +00:00
|
|
|
# Find the right boost_thread library.
|
2014-07-27 23:58:08 +00:00
|
|
|
BOOST_THREAD_LIBS=""
|
|
|
|
saved_LIBS="${LIBS}"
|
|
|
|
LIBS=""
|
2012-11-16 08:46:41 +00:00
|
|
|
AC_CHECK_LIB(boost_thread-mt, main, [],
|
|
|
|
[AC_CHECK_LIB(boost_thread, main, [],
|
|
|
|
AC_MSG_FAILURE(["Boost thread library not found."]))])
|
2014-07-27 23:58:08 +00:00
|
|
|
BOOST_THREAD_LIBS="${LIBS}"
|
|
|
|
LIBS="${saved_LIBS}"
|
|
|
|
AC_SUBST(BOOST_THREAD_LIBS)
|
2012-11-16 08:46:41 +00:00
|
|
|
|
2013-11-11 00:06:55 +00:00
|
|
|
#
|
|
|
|
# Check for boost_program_options library (defines BOOST_PROGRAM_OPTIONS_LIBS).
|
|
|
|
#
|
|
|
|
BOOST_PROGRAM_OPTIONS_LIBS=""
|
|
|
|
saved_LIBS="${LIBS}"
|
|
|
|
LIBS=""
|
|
|
|
AC_CHECK_LIB(boost_program_options-mt, main, [],
|
|
|
|
[AC_CHECK_LIB(boost_program_options, main, [],
|
|
|
|
AC_MSG_FAILURE(["Boost program options library not found."]))])
|
|
|
|
BOOST_PROGRAM_OPTIONS_LIBS="${LIBS}"
|
|
|
|
LIBS="${saved_LIBS}"
|
|
|
|
AC_SUBST(BOOST_PROGRAM_OPTIONS_LIBS)
|
|
|
|
|
2008-04-09 21:39:25 +00:00
|
|
|
AC_LANG([C])
|
2009-03-17 17:26:16 +00:00
|
|
|
|
2010-11-17 20:39:52 +00:00
|
|
|
AC_CHECK_MEMBER([struct fiemap_extent.fe_logical],
|
2010-08-06 00:19:16 +00:00
|
|
|
[AC_DEFINE([HAVE_FIEMAP_H], [], [linux/fiemap.h was found, fiemap ioctl will be used])],
|
2010-11-17 20:39:52 +00:00
|
|
|
[AC_MSG_NOTICE([linux/fiemap.h was not found or not usable; using local Ceph copy])],
|
|
|
|
[[#include <linux/fiemap.h>]])
|
2010-08-06 00:19:16 +00:00
|
|
|
|
2013-12-16 16:57:21 +00:00
|
|
|
AC_CHECK_HEADERS([ \
|
|
|
|
arpa/inet.h \
|
2014-02-10 17:34:44 +00:00
|
|
|
arpa/nameser_compat.h \
|
2013-12-16 16:57:21 +00:00
|
|
|
linux/version.h \
|
2013-12-16 16:57:21 +00:00
|
|
|
netdb.h \
|
|
|
|
netinet/in.h \
|
|
|
|
sys/file.h \
|
|
|
|
sys/ioctl.h \
|
|
|
|
sys/mount.h \
|
|
|
|
sys/param.h \
|
|
|
|
sys/socket.h \
|
|
|
|
sys/statvfs.h \
|
|
|
|
sys/time.h \
|
|
|
|
sys/vfs.h \
|
|
|
|
sys/xattr.h \
|
|
|
|
syslog.h \
|
|
|
|
utime.h \
|
|
|
|
])
|
2008-01-28 02:12:20 +00:00
|
|
|
|
2010-03-04 17:45:44 +00:00
|
|
|
# sync_file_range
|
|
|
|
AC_CHECK_FUNC([sync_file_range],
|
2010-04-16 22:25:49 +00:00
|
|
|
[AC_DEFINE([HAVE_SYNC_FILE_RANGE], [], [sync_file_range(2) is supported])],
|
2010-03-04 17:45:44 +00:00
|
|
|
[])
|
|
|
|
|
2012-03-08 22:30:06 +00:00
|
|
|
# fallocate
|
|
|
|
AC_CHECK_FUNC([fallocate],
|
2012-04-09 03:58:59 +00:00
|
|
|
[AC_DEFINE([CEPH_HAVE_FALLOCATE], [], [fallocate(2) is supported])],
|
2012-03-08 22:30:06 +00:00
|
|
|
[])
|
|
|
|
|
2013-11-07 23:38:58 +00:00
|
|
|
#
|
|
|
|
# Test for time-related `struct stat` members.
|
|
|
|
#
|
|
|
|
|
|
|
|
AC_CHECK_MEMBER([struct stat.st_mtim.tv_nsec],
|
|
|
|
[AC_DEFINE(HAVE_STAT_ST_MTIM_TV_NSEC, 1,
|
|
|
|
[Define if you have struct stat.st_mtim.tv_nsec])])
|
|
|
|
|
|
|
|
AC_CHECK_MEMBER([struct stat.st_mtimespec.tv_nsec],
|
|
|
|
[AC_DEFINE(HAVE_STAT_ST_MTIMESPEC_TV_NSEC, 1,
|
|
|
|
[Define if you have struct stat.st_mtimespec.tv_nsec])])
|
2011-01-18 10:51:32 +00:00
|
|
|
|
2013-10-20 17:46:49 +00:00
|
|
|
# splice/tee
|
|
|
|
AC_CHECK_FUNC([splice],
|
|
|
|
[AC_DEFINE([CEPH_HAVE_SPLICE], [], [splice(2) is supported])],
|
|
|
|
[])
|
|
|
|
|
2014-02-10 17:34:44 +00:00
|
|
|
# F_SETPIPE_SZ in fcntl.h
|
|
|
|
AC_MSG_CHECKING([for F_SETPIPE_SZ in fcntl.h])
|
|
|
|
AC_EGREP_CPP([yes_have_f_setpipe_sz], [
|
|
|
|
#define _GNU_SOURCE
|
|
|
|
#include <fcntl.h>
|
|
|
|
#ifdef F_SETPIPE_SZ
|
|
|
|
yes_have_f_setpipe_sz
|
|
|
|
#endif
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([yes])
|
|
|
|
AC_DEFINE([CEPH_HAVE_SETPIPE_SZ], [], [F_SETPIPE_SZ is supported])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([no])
|
|
|
|
AC_MSG_NOTICE([F_SETPIPE_SZ not found, zero-copy may be less efficent])
|
|
|
|
])
|
2013-10-18 14:46:34 +00:00
|
|
|
|
2013-11-10 23:50:13 +00:00
|
|
|
AC_CHECK_FUNCS([posix_fallocate])
|
2013-07-21 01:41:39 +00:00
|
|
|
AC_CHECK_HEADERS([sys/prctl.h])
|
|
|
|
AC_CHECK_FUNCS([prctl])
|
2013-07-21 01:41:40 +00:00
|
|
|
AC_CHECK_FUNCS([pipe2])
|
2013-07-21 01:41:39 +00:00
|
|
|
AC_CHECK_FUNCS([posix_fadvise])
|
2013-07-21 01:41:39 +00:00
|
|
|
|
2013-09-29 18:32:29 +00:00
|
|
|
AC_MSG_CHECKING([for fdatasync])
|
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
|
|
|
|
#include <unistd.h>
|
|
|
|
]], [[
|
|
|
|
#if defined(_POSIX_SYNCHRONIZED_IO) && _POSIX_SYNCHRONIZED_IO > 0
|
|
|
|
return fdatasync(0);
|
|
|
|
#else
|
|
|
|
#error Not supported
|
|
|
|
#endif
|
|
|
|
]])], [
|
|
|
|
AC_MSG_RESULT([yes])
|
|
|
|
AC_DEFINE([HAVE_FDATASYNC], 1, [Define to 1 if you have fdatasync.])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([no])
|
|
|
|
])
|
|
|
|
|
2013-07-21 01:41:40 +00:00
|
|
|
#
|
|
|
|
# Check for pthread spinlock (depends on ACX_PTHREAD)
|
|
|
|
#
|
|
|
|
saved_LIBS="$LIBS"
|
|
|
|
saved_CFLAGS="$CFLAGS"
|
|
|
|
LIBS="$PTHREAD_LIBS $LIBS"
|
|
|
|
CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
|
|
|
|
AC_CHECK_FUNC([pthread_spin_init],
|
|
|
|
[AC_DEFINE(HAVE_PTHREAD_SPINLOCK, 1, [Define if you have pthread_spin_init])])
|
|
|
|
LIBS="$saved_LIBS"
|
|
|
|
CFLAGS="$saved_CFLAGS"
|
|
|
|
|
2013-07-21 01:41:40 +00:00
|
|
|
AC_CHECK_TYPES([int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t,
|
|
|
|
int64_t, uint64_t])
|
|
|
|
|
|
|
|
dnl check for Linux types
|
|
|
|
AC_CHECK_HEADERS([linux/types.h])
|
|
|
|
AC_CHECK_TYPES([__u8, __s8, __u16, __s16, __u32, __s32, __u64, __s64, __le16,
|
|
|
|
__be16, __le32, __be32, __le64, __be64], [], [], [[#include <linux/types.h>]])
|
|
|
|
|
2014-06-12 23:27:19 +00:00
|
|
|
|
2014-08-15 22:47:18 +00:00
|
|
|
dnl Old versions of lttng-gen-tp leave out includes, and they break our stuff.
|
2014-08-18 17:58:04 +00:00
|
|
|
AC_MSG_CHECKING([if lttng-gen-tp is sane])
|
2014-08-15 22:47:18 +00:00
|
|
|
lttng_gen_tp_dir=`mktemp -d`
|
|
|
|
echo "#include <foo-inc.h>" > "$lttng_gen_tp_dir/foo.tp"
|
|
|
|
if ( ( cd "$lttng_gen_tp_dir" && lttng-gen-tp foo.tp -o foo.h && grep "#include <foo-inc.h>" foo.h ) > /dev/null 2>&1 ) ; then
|
|
|
|
have_good_lttng_gen_tp=yes
|
|
|
|
else
|
|
|
|
have_good_lttng_gen_tp=no
|
|
|
|
fi
|
|
|
|
rm -rf "$lttng_gen_tp_dir"
|
2014-08-18 17:58:04 +00:00
|
|
|
AC_MSG_RESULT([$have_good_lttng_gen_tp])
|
2014-08-15 22:47:18 +00:00
|
|
|
|
2014-07-28 16:44:42 +00:00
|
|
|
AC_ARG_WITH([lttng],
|
|
|
|
[AS_HELP_STRING([--with-lttng], [Trace with LTTng])])
|
2014-08-13 22:22:42 +00:00
|
|
|
AS_IF([test "x$with_lttng" = "xno"], [use_lttng=no],
|
|
|
|
[test "x$with_lttng" = "xyes"], [use_lttng=yes],
|
2014-08-19 18:16:50 +00:00
|
|
|
[test "x$have_good_lttng_gen_tp" = "xyes"], [use_lttng=yes; AC_MSG_NOTICE([lttng auto-enabled])],
|
2014-08-18 17:58:04 +00:00
|
|
|
[use_lttng=no; AC_MSG_NOTICE([lttng auto-disabled])])
|
2014-08-13 22:22:42 +00:00
|
|
|
AM_CONDITIONAL([WITH_LTTNG], test x"$use_lttng" = x"yes")
|
2014-07-28 16:44:42 +00:00
|
|
|
AM_COND_IF([WITH_LTTNG], [
|
|
|
|
AC_DEFINE([WITH_LTTNG], [1], [Define if you want to use LTTng])
|
2014-06-25 20:57:42 +00:00
|
|
|
|
2014-07-28 16:44:42 +00:00
|
|
|
AC_CHECK_HEADER([lttng/tracepoint.h], [],
|
2014-08-15 18:45:26 +00:00
|
|
|
AC_MSG_ERROR([lttng/tracepoint.h not found (liblttng-ust-dev, lttng-ust-devel)]))
|
|
|
|
|
2014-07-28 16:44:42 +00:00
|
|
|
AC_CHECK_PROG([LTTNG_GEN_TP_CHECK], [lttng-gen-tp], [yes])
|
|
|
|
if test x"$LTTNG_GEN_TP_CHECK" != "xyes"; then
|
|
|
|
AC_MSG_FAILURE([lttng-gen-tp not found])
|
|
|
|
fi
|
|
|
|
AC_SUBST([LTTNG_GEN_TP_PROG], [lttng-gen-tp])
|
|
|
|
|
2014-08-15 22:47:18 +00:00
|
|
|
if test x"$have_good_lttng_gen_tp" != "xyes"; then
|
|
|
|
AC_MSG_FAILURE([lttng-gen-tp does not behave properly])
|
|
|
|
fi
|
|
|
|
|
2014-07-28 16:44:42 +00:00
|
|
|
AC_MSG_CHECKING([if time_t is an integer])
|
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <time.h>]], [[
|
|
|
|
struct {
|
|
|
|
unsigned int time_t_is_integer: ((time_t) 1.5 == 1) ? 1 : -1;
|
|
|
|
} x;
|
|
|
|
return 0;
|
|
|
|
]])], [
|
|
|
|
AC_MSG_RESULT([yes])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([no])
|
|
|
|
AC_MSG_FAILURE([time_t is not an integer. We assume this for tracing.])
|
|
|
|
])
|
|
|
|
|
|
|
|
AC_MSG_CHECKING([if time_t fits in uint64_t])
|
|
|
|
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <time.h>
|
|
|
|
#include <inttypes.h>]], [[
|
|
|
|
struct {
|
|
|
|
unsigned int time_t_fits_in_uin64_t: (sizeof(time_t) <= sizeof(uint64_t)) ? 1 : -1;
|
|
|
|
} x;
|
|
|
|
return 0;
|
|
|
|
]])], [
|
|
|
|
AC_MSG_RESULT([yes])
|
|
|
|
], [
|
|
|
|
AC_MSG_RESULT([no])
|
|
|
|
AC_MSG_FAILURE([time_t is larger than uint64_t. We assume it can be cast to uint64_t, for tracing.])
|
|
|
|
])
|
2014-06-25 20:57:42 +00:00
|
|
|
], [
|
2014-07-28 16:44:42 +00:00
|
|
|
AC_DEFINE([tracepoint(...)], [], [LTTng is disabled, so define this macro to be nothing.])
|
2014-06-25 20:57:42 +00:00
|
|
|
])
|
|
|
|
|
2014-06-20 23:49:28 +00:00
|
|
|
|
2014-08-19 18:16:50 +00:00
|
|
|
AC_CHECK_HEADERS([babeltrace/ctf/events.h babeltrace/babeltrace.h])
|
|
|
|
AC_CHECK_DECL([BT_CLOCK_REAL],
|
|
|
|
[have_good_babeltrace=yes],
|
|
|
|
[have_good_babeltrace=no],
|
|
|
|
[[#include <babeltrace/babeltrace.h>]])
|
|
|
|
AC_ARG_WITH([babeltrace],
|
|
|
|
[AS_HELP_STRING([--with-babeltrace], [Enable Babeltrace])])
|
|
|
|
AS_IF([test "x$with_babeltrace" = "xno"], [use_babeltrace=no],
|
|
|
|
[test "x$with_babeltrace" = "xyes"], [use_babeltrace=yes],
|
|
|
|
[test "x$ac_cv_header_babeltrace_ctf_events_h$ac_cv_header_babeltrace_babeltrace_h$have_good_babeltrace" = "xyesyesyes"], [use_babeltrace=yes; AC_MSG_NOTICE([babeltrace auto-enabled])],
|
|
|
|
[use_babeltrace=no; AC_MSG_NOTICE([babeltrace auto-disabled])])
|
|
|
|
AM_CONDITIONAL([WITH_BABELTRACE], test x"$use_babeltrace" = x"yes")
|
|
|
|
AM_COND_IF([WITH_BABELTRACE], [
|
|
|
|
AC_DEFINE([WITH_BABELTRACE], [1], [Define if you want to use Babeltrace])
|
|
|
|
|
|
|
|
AC_CHECK_HEADER([babeltrace/babeltrace.h], [],
|
|
|
|
AC_MSG_ERROR([babeltrace/babeltrac.h not found (libbabeltrace-dev, libbabeltrace-devel)]))
|
|
|
|
|
|
|
|
AC_CHECK_HEADER([babeltrace/ctf/events.h], [],
|
|
|
|
AC_MSG_ERROR([babeltrace/ctf/events.h not found (libbabeltrace-ctf-dev, libbabeltrace-devel)]))
|
|
|
|
])
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
# Checks for typedefs, structures, and compiler characteristics.
|
2009-03-04 00:45:58 +00:00
|
|
|
#AC_HEADER_STDBOOL
|
|
|
|
#AC_C_CONST
|
|
|
|
#AC_TYPE_UID_T
|
|
|
|
#AC_C_INLINE
|
|
|
|
#AC_TYPE_INT16_T
|
|
|
|
#AC_TYPE_INT32_T
|
|
|
|
#AC_TYPE_INT64_T
|
|
|
|
#AC_TYPE_INT8_T
|
|
|
|
#AC_TYPE_MODE_T
|
|
|
|
#AC_TYPE_OFF_T
|
|
|
|
#AC_TYPE_PID_T
|
|
|
|
#AC_TYPE_SIZE_T
|
|
|
|
#AC_TYPE_SSIZE_T
|
|
|
|
#AC_CHECK_MEMBERS([struct stat.st_blksize])
|
|
|
|
#AC_STRUCT_ST_BLOCKS
|
|
|
|
#AC_CHECK_MEMBERS([struct stat.st_rdev])
|
|
|
|
#AC_HEADER_TIME
|
|
|
|
#AC_STRUCT_TM
|
|
|
|
#AC_TYPE_UINT16_T
|
|
|
|
#AC_TYPE_UINT32_T
|
|
|
|
#AC_TYPE_UINT64_T
|
|
|
|
#AC_TYPE_UINT8_T
|
2008-01-28 02:12:20 +00:00
|
|
|
|
|
|
|
# Checks for library functions.
|
2008-03-13 02:36:54 +00:00
|
|
|
#AC_FUNC_CHOWN
|
|
|
|
#AC_FUNC_CLOSEDIR_VOID
|
|
|
|
#AC_FUNC_ERROR_AT_LINE
|
|
|
|
#AC_FUNC_FORK
|
|
|
|
#AC_PROG_GCC_TRADITIONAL
|
|
|
|
#AC_FUNC_LSTAT
|
|
|
|
#AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK
|
2008-02-01 17:59:44 +00:00
|
|
|
#AC_FUNC_MALLOC # this causes annoying rpl_malloc error on some machines; skip it
|
2008-03-13 02:36:54 +00:00
|
|
|
#AC_FUNC_MEMCMP
|
|
|
|
#AC_FUNC_MMAP
|
|
|
|
#AC_FUNC_REALLOC
|
|
|
|
#AC_FUNC_SELECT_ARGTYPES
|
|
|
|
#AC_TYPE_SIGNAL
|
|
|
|
#AC_FUNC_STAT
|
|
|
|
#AC_FUNC_UTIME_NULL
|
|
|
|
#AC_CHECK_FUNCS([bzero fchdir fdatasync floor ftruncate getcwd gethostbyname gethostname gettimeofday inet_ntoa localtime_r memmove memset mkdir munmap pow rmdir select socket sqrt strcasecmp strchr strerror strstr utime])
|
2008-01-28 02:12:20 +00:00
|
|
|
|
2014-04-09 04:06:55 +00:00
|
|
|
# check for return type (and presence) if strerror_r in C++ mode
|
|
|
|
AC_LANG_PUSH([C++])
|
|
|
|
AC_FUNC_STRERROR_R
|
|
|
|
AC_LANG_POP([C++])
|
|
|
|
|
2011-07-13 23:11:43 +00:00
|
|
|
AM_CONDITIONAL(WITH_BUILD_TESTS, test "$WITH_BUILD_TESTS" = "1")
|
|
|
|
|
2011-02-09 16:47:56 +00:00
|
|
|
AM_PATH_PYTHON([2.4],
|
|
|
|
[], [AC_MSG_FAILURE([Failed to find Python 2.4 or newer])])
|
|
|
|
|
2008-01-28 02:12:20 +00:00
|
|
|
AC_CONFIG_HEADERS([src/acconfig.h])
|
|
|
|
AC_CONFIG_FILES([Makefile
|
2008-07-11 22:56:28 +00:00
|
|
|
src/Makefile
|
2011-12-29 19:58:01 +00:00
|
|
|
src/ocf/Makefile
|
|
|
|
src/ocf/ceph
|
2012-03-03 23:40:55 +00:00
|
|
|
src/ocf/rbd
|
2012-09-01 17:26:41 +00:00
|
|
|
src/java/Makefile
|
2014-05-30 21:13:12 +00:00
|
|
|
src/tracing/Makefile
|
2009-03-10 21:39:54 +00:00
|
|
|
man/Makefile
|
2008-07-11 22:56:28 +00:00
|
|
|
ceph.spec])
|
2008-01-28 02:12:20 +00:00
|
|
|
AC_OUTPUT
|