summaryrefslogtreecommitdiff
path: root/cpp/configure.ac
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2007-08-01 16:01:34 +0000
committerAlan Conway <aconway@apache.org>2007-08-01 16:01:34 +0000
commit9235b5d09b3273c7c495ff266e18781fad363a9b (patch)
tree2d1d3d1416bf4a0616ce3ca3d287103fe8a98d42 /cpp/configure.ac
parent7c16ea45a0193861868f27a53403995d57e49e66 (diff)
downloadqpid-python-9235b5d09b3273c7c495ff266e18781fad363a9b.tar.gz
* configure.ac: --disable-cluster flag.
* qpidc.spec.in: openais dependency removed by --disable-flag git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@561848 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/configure.ac')
-rw-r--r--cpp/configure.ac25
1 files changed, 17 insertions, 8 deletions
diff --git a/cpp/configure.ac b/cpp/configure.ac
index 20c6426188..f94710232a 100644
--- a/cpp/configure.ac
+++ b/cpp/configure.ac
@@ -142,20 +142,29 @@ AC_SUBST(DOWNLOAD_URL)
AC_CHECK_HEADERS([boost/shared_ptr.hpp uuid/uuid.h],,
AC_MSG_ERROR([Missing required header files.]))
-# Check for cluster requirements.
+# Check for cluster requirements. Need openais 0.80.3 or higher.x1
save_ldflags=$LDFLAGS
- LDFLAGS="$LDFLAGS -L/usr/lib/openais -L/usr/lib64/openais"
+LDFLAGS="$LDFLAGS -L/usr/lib/openais -L/usr/lib64/openais"
AC_CHECK_LIB([cpg],[cpg_local_get],[cpg_lib=yes])
AC_CHECK_HEADER([openais/cpg.h],[cpg_h=yes])
-if test x$cpg_lib = xyes -a x$cpg_h = xyes; then
- enable_CLUSTER=yes;
- CPPFLAGS+=" -DCLUSTER"
+test x$cpg_lib = xyes -a x$cpg_h = xyes && enable_CLUSTER=yes
+
+if test x$enable_CLUSTER = xyes; then
+ AC_ARG_ENABLE([cluster],
+ [AS_HELP_STRING([--disable-cluster],
+ [disable cluster functionality (default enabled)])],
+ [enable_CLUSTER=$enableval])
+fi
+AM_CONDITIONAL([CLUSTER], [test x$enable_CLUSTER = xyes])
+if test x$enable_CLUSTER = xyes; then
+ CPPFLAGS+=" -DCLUSTER"
+ REQUIRES_OPENAIS="Requires: openais"
+ AC_SUBST(REQUIRES_OPENAIS)
+ REQUIRES_OPENAIS_DEVEL="Requires: openais-devel"
+ AC_SUBST(REQUIRES_OPENAIS_DEVEL)
else
- enable_CLUSTER=no;
LDFLAGS=$save_ldflags
fi
-AM_CONDITIONAL([CLUSTER], [test x$enable_CLUSTER = xyes])
-
# Files to generate
AC_CONFIG_FILES([