# All paths should be given relative to the root
EXTRA_DIST+= \
- libmemcached/libmemcached.ver \
libmemcached/libmemcached_probes.d \
libmemcached/memcached/README.txt \
- libmemcached/memcached_configure.h.in \
- libmemcached/protocol/libmemcachedprotocol.ver \
- libmemcached/util/libmemcachedutil.ver
+ libmemcached/memcached_configure.h.in
noinst_HEADERS+= \
+++ /dev/null
-libmemcached_3 { global: *; };
+++ /dev/null
-libmemcachedprotocol_0 { global: *; };
+++ /dev/null
-libmemcachedutil_0 { global: *; };
dnl with or without modifications, as long as this notice is preserved.
dnl Which version of the canonical setup we're using
-AC_DEFUN([PANDORA_CANONICAL_VERSION],[0.80])
+AC_DEFUN([PANDORA_CANONICAL_VERSION],[0.86])
AC_DEFUN([PANDORA_FORCE_DEPEND_TRACKING],[
dnl Force dependency tracking on for Sun Studio builds
PANDORA_LIBTOOL
- AS_IF([test "$lt_cv_prog_gnu_ld" = "yes"],[
- ${LD} --help | grep default-symver >/dev/null 2>&1
- AS_IF([test $? -eq 0],[
- AM_LDFLAGS="${AM_LDFLAGS} -Wl,--default-symver"
- ])
- ])
-
dnl autoconf doesn't automatically provide a fail-if-no-C++ macro
dnl so we check c++98 features and fail if we don't have them, mainly
dnl for that reason
dnl alloca - but we need to know it anyway for check_stack_overrun.
PANDORA_STACK_DIRECTION
- save_LIBS="${LIBS}"
- LIBS=""
- AC_CHECK_LIB(m, floor, [], AC_CHECK_LIB(m, __infinity))
- LIBM="${LIBS}"
- LIBS="${save_LIBS}"
- AC_SUBST([LIBM])
+ AC_CHECK_LIBM
AC_CHECK_FUNC(setsockopt, [], [AC_CHECK_LIB(socket, setsockopt)])
AC_CHECK_FUNC(bind, [], [AC_CHECK_LIB(bind, bind)])
AC_SUBST([AM_CFLAGS])
AC_SUBST([AM_CXXFLAGS])
AC_SUBST([AM_CPPFLAGS])
- AC_SUBST([AM_LDFLAGS])
])
AS_IF([test "$GCC" = "yes"],
[AS_IF([test "$ac_cv_cxx_compile_cxx0x_native" = "yes"],[],
[AS_IF([test "$ac_cv_cxx_compile_cxx0x_gxx" = "yes"],
- [CXXFLAGS="-std=gnu++0x ${CXXFLAGS}"],
- [CXXFLAGS="-std=gnu++98"])
+ [CXX_STANDARD="-std=gnu++0x"],
+ [CXX_STANDARD="-std=gnu++98"])
])
])
+ AM_CXXFLAGS="${CXX_STANDARD} ${AM_CXXFLAGS}"
+
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${CXXFLAGS} ${CXX_STANDARD}"
AC_CXX_HEADER_STDCXX_98
+ CXXFLAGS="${save_CXXFLAGS}"
+
+ AC_SUBST([CXX_STANDARD])
])
[AC_REQUIRE([PANDORA_CXX_CSTDINT])
AC_MSG_CHECKING(the location of cinttypes)
AC_LANG_PUSH(C++)
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${CXX_STANDARD} ${CXXFLAGS}"
ac_cv_cxx_cinttypes=""
for location in tr1/cinttypes boost/cinttypes cinttypes; do
if test -z "$ac_cv_cxx_cinttypes"; then
fi
done
AC_LANG_POP()
+ CXXFLAGS="${save_CXXFLAGS}"
if test -n "$ac_cv_cxx_cinttypes"; then
AC_MSG_RESULT([$ac_cv_cxx_cinttypes])
else
- AC_DEFINE([__STDC_LIMIT_MACROS],[1],[Use STDC Limit Macros in C++])
ac_cv_cxx_cinttypes="<inttypes.h>"
AC_MSG_RESULT()
AC_MSG_WARN([Could not find a cinttypes header.])
fi
+ AC_DEFINE([__STDC_LIMIT_MACROS],[1],[Use STDC Limit Macros in C++])
AC_DEFINE_UNQUOTED(CINTTYPES_H,$ac_cv_cxx_cinttypes,
[the location of <cinttypes>])
])
AC_DEFUN([PANDORA_CXX_CSTDINT],
[AC_MSG_CHECKING(the location of cstdint)
AC_LANG_PUSH(C++)
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${CXX_STANDARD} ${CXXFLAGS}"
ac_cv_cxx_cstdint=""
for location in tr1/cstdint boost/cstdint cstdint; do
if test -z "$ac_cv_cxx_cstdint"; then
fi
done
AC_LANG_POP()
+ CXXFLAGS="${save_CXXFLAGS}"
if test -n "$ac_cv_cxx_cstdint"; then
AC_MSG_RESULT([$ac_cv_cxx_cstdint])
else
AC_DEFUN([PANDORA_CXX_DEMANGLE],[
AC_LANG_PUSH([C++])
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${CXX_STANDARD} ${CXXFLAGS}"
AC_CHECK_HEADERS(cxxabi.h)
AC_CACHE_CHECK([checking for abi::__cxa_demangle], pandora_cv_cxa_demangle,
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <cxxabi.h>]], [[
char *foo= 0; int bar= 0;
foo= abi::__cxa_demangle(foo, foo, 0, &bar);
]])],[pandora_cv_cxa_demangle=yes],[pandora_cv_cxa_demangle=no])])
+ CXXFLAGS="${save_CXXFLAGS}"
AC_LANG_POP()
AS_IF([test "x$pandora_cv_cxa_demangle" = xyes],[
AC_DEFUN([PANDORA_DRIZZLE_BUILD],[
dnl We need to turn on our CXXFLAGS to make sure it shows up correctly
- save_CXXFLAGS="${CXXFLAGS}"
- CXXFLAGS="${CXXFLAGS} ${AM_CXXFLAGS}"
PANDORA_CXX_STL_HASH
- CXXFLAGS="${save_CXXFLAGS}"
PANDORA_CXX_CSTDINT
PANDORA_CXX_CINTTYPES
AC_HEADER_SYS_WAIT
AC_HEADER_STDBOOL
- AC_CHECK_HEADERS(sys/fpu.h fpu_control.h ieeefp.h)
+ AC_CHECK_HEADERS(sys/types.h sys/fpu.h fpu_control.h ieeefp.h)
AC_CHECK_HEADERS(select.h sys/select.h)
AC_CHECK_HEADERS(utime.h sys/utime.h )
AC_CHECK_HEADERS(synch.h sys/mman.h sys/socket.h)
# include <curses.h>
#endif
]])
- AC_CHECK_TYPES([ulong])
+ AC_CHECK_TYPES([uint, ulong])
PANDORA_CXX_DEMANGLE
+ AH_TOP([
+#ifndef __CONFIG_H__
+#define __CONFIG_H__
+
+#if defined(i386) && !defined(__i386__)
+#define __i386__
+#endif
+
+ ])
+ AH_BOTTOM([
+#if defined(__cplusplus)
+# include CSTDINT_H
+# include CINTTYPES_H
+#else
+# include <stdint.h>
+# include <inttypes.h>
+#endif
+
+#if !defined(HAVE_ULONG) && !defined(__USE_MISC)
+typedef unsigned long int ulong;
+#endif
+
+#endif /* __CONFIG_H__ */
+ ])
])
[Does system provide rl_compentry_func_t])
])
- AC_LANG_PUSH(C++)
save_CXXFLAGS="${CXXFLAGS}"
CXXFLAGS="${AM_CXXFLAGS} ${CXXFLAGS}"
+ AC_LANG_PUSH(C++)
AC_CACHE_CHECK([rl_compentry_func_t works], [pandora_cv_rl_compentry_works],[
AC_COMPILE_IFELSE([
AC_LANG_PROGRAM([[
dnl with or without modifications, as long as this notice is preserved.
AC_DEFUN([PANDORA_LIBTOOL],[
+ AC_REQUIRE([AC_DISABLE_STATIC])
AC_REQUIRE([AC_PROG_LIBTOOL])
+ m4_ifndef([LT_PREREQ],[
+ pandora_have_old_libtool=yes
+ ],[
+ pandora_have_old_libtool=no
+ ])
+ AS_IF([test "$SUNCC" = "yes" -a "${pandora_have_old_libtool}" = "yes"],[
+ AC_MSG_ERROR([Building ${PACKAGE} with Sun Studio requires at least libtool 2.2])
+ ])
+
dnl By requiring AC_PROG_LIBTOOL, we should force the macro system to read
dnl libtool.m4, where in 2.2 AC_PROG_LIBTOOL is an alias for LT_INIT
dnl Then, if we're on 2.2, we should have LT_LANG, so we'll call it.
AC_DEFUN([PANDORA_SHARED_PTR],[
AC_REQUIRE([PANDORA_CHECK_CXX_STANDARD])
AC_LANG_PUSH(C++)
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${CXX_STANDARD} ${CXXFLAGS}"
AC_CHECK_HEADERS(memory tr1/memory boost/shared_ptr.hpp)
AC_CACHE_CHECK([the location of shared_ptr header file],
[ac_cv_shared_ptr_h],[
AC_DEFINE_UNQUOTED([SHARED_PTR_NAMESPACE],
${ac_cv_shared_ptr_namespace},
[The namespace in which SHARED_PTR can be found])
+ CXXFLAGS="${save_CXXFLAGS}"
AC_LANG_POP()
])
AC_DEFUN([PANDORA_CXX_STL_HASH],
[AC_MSG_CHECKING(the location of hash_map)
+ save_CXXFLAGS="${CXXFLAGS}"
+ CXXFLAGS="${AM_CXXFLAGS} ${CXXFLAGS}"
AC_LANG_PUSH(C++)
ac_cv_cxx_hash_map=""
for location in "" "ext/" "tr1/" ; do
AS_IF([test $ac_cv_redefine_hash_string = yes],[
AC_DEFINE(REDEFINE_HASH_STRING, 1, [if hash<string> needs to be defined])
])
+ CXXFLAGS="${save_CXXFLAGS}"
AC_LANG_POP()
])
AS_IF([test "$ac_profiling" = "yes"],[
CC_PROFILING="-pg"
+ GCOV_LIBS="-pg -lgcov"
save_LIBS="${LIBS}"
LIBS=""
AC_CHECK_LIB(c_p, read)
])
AS_IF([test "$ac_coverage" = "yes"],
- [CC_COVERAGE="-fprofile-arcs -ftest-coverage"])
+ [
+ CC_COVERAGE="--coverage"
+ GCOV_LIBS="-lgcov"
+ ])
+
+
AS_IF([test "$ac_cv_warnings_as_errors" = "yes"],
[W_FAIL="-Werror"])
AS_IF([test "$INTELCC" = "yes"],[
m4_if(PW_LESS_WARNINGS,[no],[
- BASE_WARNINGS="-w1 -Wall -Werror -Wcheck -Wformat -Wp64 -Woverloaded-virtual -Wcast-qual"
+ BASE_WARNINGS="-w1 -Werror -Wcheck -Wformat -Wp64 -Woverloaded-virtual -Wcast-qual"
],[
- BASE_WARNINGS="-w1 -Wall -Wcheck -Wformat -Wp64 -Woverloaded-virtual -Wcast-qual -diag-disable 981"
+ BASE_WARNINGS="-w1 -Wcheck -Wformat -Wp64 -Woverloaded-virtual -Wcast-qual -diag-disable 981"
])
CC_WARNINGS="${BASE_WARNINGS}"
CXX_WARNINGS="${BASE_WARNINGS}"
AC_INCLUDES_DEFAULT])],
[ac_cv_safe_to_use_Wredundant_decls_=yes],
[ac_cv_safe_to_use_Wredundant_decls_=no])
- CXXFLAGS="${save_CXXFLAGS}"
- AC_LANG_POP()])
+ CXXFLAGS="${save_CXXFLAGS}"
+ AC_LANG_POP()])
AS_IF([test "$ac_cv_safe_to_use_Wredundant_decls_" = "yes"],
[CXX_WARNINGS="${CXX_WARNINGS} -Wredundant-decls"],
[CXX_WARNINGS="${CXX_WARNINGS} -Wno-redundant-decls"])
AC_SUBST(PROTOSKIP_WARNINGS)
AC_SUBST(INNOBASE_SKIP_WARNINGS)
AC_SUBST(NO_WERROR)
+ AC_SUBST([GCOV_LIBS])
])