summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in38
1 files changed, 34 insertions, 4 deletions
diff --git a/configure.in b/configure.in
index 76105c5..45117e6 100644
--- a/configure.in
+++ b/configure.in
@@ -17,15 +17,24 @@ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
# This lets us use PACKAGE_VERSION in Makefiles
AC_SUBST(PACKAGE_VERSION)
-# Libtool -version-info (ABI version)
+# ABI version for libxs (Libtool -version-info)
#
# Don't change this unless you know exactly what you're doing and have read and
# understand:
# http://www.gnu.org/software/libtool/manual/html_node/Updating-version-info.html
#
# libxs -version-info current:revision:age
-LTVER="0:0:0"
-AC_SUBST(LTVER)
+LIBXS_ABI_VERSION="0:0:0"
+AC_SUBST(LIBXS_ABI_VERSION)
+
+# ABI version for libxszmq
+#
+# This must be set to the ABI version of libzmq we are emulating.
+# This is currently libzmq 2.1 which is ABI 1.0.0.
+#
+# libxszmq -version-info current:revision:age
+LIBXSZMQ_ABI_VERSION="1:0:0"
+AC_SUBST(LIBXSZMQ_ABI_VERSION)
# Take a copy of original flags
XS_ORIG_CFLAGS="${CFLAGS:-none}"
@@ -268,6 +277,17 @@ AC_HEADER_TIME
AC_TYPE_UINT32_T
AC_C_VOLATILE
+# libzmq compatibility mode
+libxs_libzmq_compat="no"
+AC_ARG_ENABLE([libzmq-compat], [AS_HELP_STRING([--enable-libzmq-compat],
+ [install libzmq compatibility library and headers [default=no]])],
+ [enable_libzmq_compat=$enableval], [enable_libzmq_compat=no])
+
+if test "x$enable_libzmq_compat" != "xno"; then
+ AC_MSG_NOTICE([enabling libzmq compatibility library and headers])
+ libxs_libzmq_compat="yes"
+fi
+
# PGM extension
libxs_pgm_ext="no"
@@ -360,6 +380,7 @@ if test "x$libxs_pedantic" = "xyes"; then
fi
AC_LANG_POP([C++])
+AM_CONDITIONAL(BUILD_LIBZMQ, test "x$libxs_libzmq_compat" = "xyes")
AM_CONDITIONAL(BUILD_PGM, test "x$libxs_pgm_ext" = "xyes")
AM_CONDITIONAL(ON_MINGW, test "x$libxs_on_mingw32" = "xyes")
@@ -379,8 +400,17 @@ AC_SUBST(LIBXS_EXTRA_CXXFLAGS)
AC_SUBST(LIBXS_EXTRA_LDFLAGS)
AC_CONFIG_FILES([Makefile src/Makefile doc/Makefile
- perf/Makefile src/libxs.pc \
+ perf/Makefile src/libxs.pc src/libxszmq.pc \
builds/msvc/Makefile tests/Makefile \
foreign/openpgm/Makefile])
+if test "x$libxs_libzmq_compat" == "xyes"; then
+ AC_CONFIG_FILES([src/libzmq.pc])
+fi
AC_OUTPUT
+if test "x$libxs_libzmq_compat" == "xyes"; then
+ AC_MSG_WARN([The --enable-libzmq-compat option was specified:])
+ AC_MSG_WARN([libzmq compatibility library and headers are enabled.])
+ AC_MSG_WARN([This will overwrite any existing installation of libzmq.])
+fi
+