Fixing a couple of items before releasing.
[awesomized/libmemcached] / m4 / pandora_canonical.m4
index 49d4fc4955768cda61d0df2b4aa9518385c09a55..9f6d514c5d46621300e062ec5eb52aed4757bdd3 100644 (file)
@@ -6,23 +6,6 @@ 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.175])
 
-AC_DEFUN([PANDORA_FORCE_DEPEND_TRACKING],[
-  AC_ARG_ENABLE([fat-binaries],
-    [AS_HELP_STRING([--enable-fat-binaries],
-      [Enable fat binary support on OSX @<:@default=off@:>@])],
-    [ac_enable_fat_binaries="$enableval"],
-    [ac_enable_fat_binaries="no"])
-
-  dnl Force dependency tracking on for Sun Studio builds
-  AS_IF([test "x${enable_dependency_tracking}" = "x"],[
-    enable_dependency_tracking=yes
-  ])
-  dnl If we're building OSX Fat Binaries, we have to turn off -M options
-  AS_IF([test "x${ac_enable_fat_binaries}" = "xyes"],[
-    enable_dependency_tracking=no
-  ])
-])
-
 AC_DEFUN([PANDORA_BLOCK_BAD_OPTIONS],[
   AS_IF([test "x${prefix}" = "x"],[
     AC_MSG_ERROR([--prefix requires an argument])
@@ -31,7 +14,6 @@ AC_DEFUN([PANDORA_BLOCK_BAD_OPTIONS],[
 
 dnl The standard setup for how we build Pandora projects
 AC_DEFUN([PANDORA_CANONICAL_TARGET],[
-  AC_REQUIRE([PANDORA_FORCE_DEPEND_TRACKING])
   ifdef([m4_define],,[define([m4_define],   defn([define]))])
   ifdef([m4_undefine],,[define([m4_undefine],   defn([undefine]))])
   m4_define([PCT_ALL_ARGS],[$*])
@@ -79,7 +61,7 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
   AS_IF([test "x${ac_cv_env_CXXFLAGS_set}" = "x"],
         [CXXFLAGS=""])
   
-  AM_INIT_AUTOMAKE(-Wall -Werror -Wno-portability subdir-objects foreign tar-ustar)
+  AM_INIT_AUTOMAKE([-Wall -Werror -Wno-portability subdir-objects foreign tar-ustar])
 
   m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
 
@@ -132,29 +114,19 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
   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
-  PANDORA_CHECK_CXX_STANDARD
   m4_if(PCT_REQUIRE_CXX, [yes], [
     AS_IF([test "$ac_cv_cxx_stdcxx_98" = "no"],[
       AC_MSG_ERROR([No working C++ Compiler has been found. ${PACKAGE} requires a C++ compiler that can handle C++98])
     ])
   ])
-  PANDORA_CXX_CSTDINT
-  PANDORA_CXX_CINTTYPES
   
   m4_if(m4_substr(m4_esyscmd(test -d gnulib && echo 0),0,1),0,[
     gl_INIT
     AC_CONFIG_LIBOBJ_DIR([gnulib])
   ])
 
-  PANDORA_CHECK_C_VERSION
   PANDORA_CHECK_CXX_VERSION
 
-  AC_C_BIGENDIAN
-  AC_C_CONST
-  AC_C_INLINE
-  AC_C_VOLATILE
-  AC_C_RESTRICT
-
   AC_HEADER_TIME
   AC_STRUCT_TM
   AC_TYPE_SIZE_T
@@ -195,25 +167,6 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
     AC_DEFINE([TIME_T_UNSIGNED], 1, [Define to 1 if time_t is unsigned])
   ])
 
-  AC_CACHE_CHECK([if system defines RUSAGE_THREAD], [ac_cv_rusage_thread],[
-  AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
-      [[
-#include <sys/time.h>
-#include <sys/resource.h>
-      ]],[[
-      int x= RUSAGE_THREAD;
-      ]])
-    ],[
-      ac_cv_rusage_thread=yes
-    ],[
-      ac_cv_rusage_thread=no
-    ])
-  ])
-  AS_IF([test "$ac_cv_rusage_thread" = "no"],[
-    AC_DEFINE([RUSAGE_THREAD], [RUSAGE_SELF],
-      [Define if system doesn't define])
-  ])
-
   AC_CHECK_FUNC(setsockopt, [], [AC_CHECK_LIB(socket, setsockopt)])
   AC_CHECK_FUNC(bind, [], [AC_CHECK_LIB(bind, bind)])
 
@@ -221,17 +174,6 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
 
   PANDORA_OPTIMIZE
 
-  AC_LANG_PUSH(C++)
-  # Test whether madvise() is declared in C++ code -- it is not on some
-  # systems, such as Solaris
-  AC_CHECK_DECLS([madvise], [], [], [AC_INCLUDES_DEFAULT[
-  #if HAVE_SYS_MMAN_H
-  #include <sys/types.h>
-  #include <sys/mman.h>
-  #endif
-  ]])
-  AC_LANG_POP()
-
   PANDORA_HAVE_GCC_ATOMICS
 
   PANDORA_HEADER_ASSERT
@@ -242,9 +184,7 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
 
   AC_LIB_PREFIX
   PANDORA_HAVE_BETTER_MALLOC
-  PANDORA_WITH_VALGRIND
 
-  AC_CHECK_PROGS([DOXYGEN], [doxygen])
   AC_CHECK_PROGS([PERL], [perl])
   AC_CHECK_PROGS([DPKG_GENSYMBOLS], [dpkg-gensymbols], [:])
   AC_CHECK_PROGS([LCOV], [lcov], [echo lcov not found])
@@ -265,13 +205,6 @@ AC_DEFUN([PANDORA_CANONICAL_TARGET],[
   AM_CONDITIONAL(HAVE_SPHINX,[test "x${SPHINXBUILD}" != "x:"])
   AM_CONDITIONAL(HAVE_RECENT_SPHINX,[test "x${ac_cv_recent_sphinx}" = "xyes"])
 
-  AS_IF([test "x${gl_LIBOBJS}" != "x"],[
-    AS_IF([test "$GCC" = "yes"],[
-      AM_CPPFLAGS="-isystem \${top_srcdir}/gnulib -isystem \${top_builddir}/gnulib ${AM_CPPFLAGS}"
-    ],[
-    AM_CPPFLAGS="-I\${top_srcdir}/gnulib -I\${top_builddir}/gnulib ${AM_CPPFLAGS}"
-    ])
-  ])
   m4_if(m4_substr(m4_esyscmd(test -d src && echo 0),0,1),0,[
     AM_CPPFLAGS="-I\$(top_srcdir)/src -I\$(top_builddir)/src ${AM_CPPFLAGS}"
   ],[