]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rhel 5.9 port fixes to compile librados only 4004/head
authorRohan Mars <code@rohanmars.com>
Sun, 15 Mar 2015 19:28:06 +0000 (12:28 -0700)
committerRohan Mars <code@rohanmars.com>
Sun, 15 Mar 2015 19:28:06 +0000 (12:28 -0700)
Signed-off-by: Rohan Mars <code@rohanmars.com>
configure.ac
src/Makefile-env.am
src/common/Makefile.am
src/mon/MonCap.cc

index a035fc46ae7f81c60abc214941a43967a47fea69..6528abd96d1eae0c940499a8f38546d56e55fd8c 100644 (file)
@@ -242,6 +242,7 @@ AC_DEFUN([AC_CHECK_CC_FLAG],
 
 AC_CHECK_CC_FLAG([-Wtype-limits], [WARN_TYPE_LIMITS])
 AC_CHECK_CC_FLAG([-Wignored-qualifiers], [WARN_IGNORED_QUALIFIERS])
+AC_CHECK_CC_FLAG([-Werror=format-security], [WARN_ERROR_FORMAT_SECURITY])
 
 # Check for compiler VTA support
 AX_CHECK_COMPILE_FLAG([-fvar-tracking-assignments], [HAS_VTA_SUPPORT=1], [HAS_VTA_SUPPORT=0])
@@ -257,7 +258,7 @@ ACX_PTHREAD
 AC_CHECK_LIB([uuid], [uuid_parse], [true], AC_MSG_FAILURE([libuuid not found]))
 
 # rbd {map,unmap,showmapped} dependencies, Linux only
-if test x"$linux" = x"yes"; then
+if test x"$linux" = x"yes" -a x"$with_rbd" = x"yes"; then
   # libblkid
   AC_CHECK_HEADER([blkid/blkid.h], [],
     AC_MSG_ERROR([blkid/blkid.h not found (libblkid-dev, libblkid-devel)]))
@@ -645,7 +646,7 @@ fi
 #
 # FreeBSD has it in base.
 #
-if test x"$freebsd" != x"yes"; then
+if test x"$freebsd" != x"yes" -a x"$with_radosgw" = x"yes"; then
 PKG_CHECK_MODULES([LIBEDIT], [libedit >= 2.11],
                 [], AC_MSG_FAILURE([No usable version of libedit found.]))
 else
@@ -966,6 +967,7 @@ AC_MSG_RESULT([no])
 ])
 
 AC_MSG_CHECKING([for sched.h])
++AC_LANG_PUSH([C++])
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
 #define _GNU_SOURCE
 #include <sched.h>
@@ -982,6 +984,8 @@ AC_DEFINE([HAVE_SCHED], 1, [Define to 1 if you have sched.h.])
 ], [
 AC_MSG_RESULT([no])
 ])
++AC_LANG_POP([C++])
+
 
 #
 # Check for pthread spinlock (depends on ACX_PTHREAD)
index aca2d399d449a73f0e9116cb8832541e1fe8622c..ea7eabc7afce53bef13cd8ca856c6233feb66f7a 100644 (file)
@@ -64,7 +64,7 @@ AM_COMMON_CFLAGS = \
        ${WARN_IGNORED_QUALIFIERS} \
        -Winit-self \
        -Wpointer-arith \
-       -Werror=format-security \
+       ${WARN_ERROR_FORMAT_SECURITY} \
        -fno-strict-aliasing \
        -fsigned-char
 if !CLANG
index a0736ba821fa1ae3d70c0b5411c5d333068138cf..78afd5e9d88a42ff5a50339b2d1a5e16933f0376 100644 (file)
@@ -33,7 +33,6 @@ libcommon_internal_la_SOURCES = \
        common/str_map.cc \
        common/errno.cc \
        common/RefCountedObj.cc \
-       common/blkdev.cc \
        common/common_init.cc \
        common/pipe.c \
        common/ceph_argparse.cc \
@@ -76,6 +75,11 @@ libcommon_internal_la_SOURCES = \
        common/Cycles.cc \
        common/ContextCompletion.cc
 
+if WITH_RBD
+libcommon_internal_la_SOURCES += \
+       common/blkdev.cc
+endif
+
 if ENABLE_XIO
 libcommon_internal_la_SOURCES += \
        common/address_helper.cc
index 059eeabf0116873551a2fb3d956ca600c0b5dd15..307e0f308a2e9eedd60eb9144934af44daab2165 100644 (file)
  */
 
 #include <boost/config/warning_disable.hpp>
+#include <boost/spirit/include/qi_uint.hpp>
 #include <boost/spirit/include/qi.hpp>
 #include <boost/fusion/include/std_pair.hpp>
 #include <boost/spirit/include/phoenix.hpp>
-#include <boost/spirit/include/qi_uint.hpp>
 #include <boost/fusion/adapted/struct/adapt_struct.hpp>
 #include <boost/fusion/include/adapt_struct.hpp>