summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp')
-rw-r--r--cpp/configure.ac7
-rw-r--r--cpp/etc/Makefile.am2
2 files changed, 6 insertions, 3 deletions
diff --git a/cpp/configure.ac b/cpp/configure.ac
index adcf4c5dd2..4eec5f1235 100644
--- a/cpp/configure.ac
+++ b/cpp/configure.ac
@@ -330,9 +330,12 @@ AS_IF([test "x$WANT_SASL" != xno],
[AC_DEFINE([BROKER_SASL_NAME], ["qpidd"],
[The SASL app name for the qpid Broker])
AC_DEFINE([HAVE_SASL], [1], [Enable if libsasl is present])
- have_sasl=yes])])
+ have_sasl=yes])
+ AC_PATH_PROG([SASL_PASSWD], [saslpasswd2], [], [$PATH$PATH_SEPARATOR/usr/sbin])
+ AS_IF([test x$SASL_PASSWD = x], [AC_MSG_ERROR([saslpasswd2 not found])], [])
+ ])
AM_CONDITIONAL([HAVE_SASL], [test "x$have_sasl" = xyes])
-
+AC_SUBST([SASL_PASSWD])
# Setup --with-xml/--without-xml as arguments to configure
use_xml=yes
diff --git a/cpp/etc/Makefile.am b/cpp/etc/Makefile.am
index 8731641360..c91dbcbbad 100644
--- a/cpp/etc/Makefile.am
+++ b/cpp/etc/Makefile.am
@@ -52,7 +52,7 @@ sasldb_DATA = $(SASL_DB)
# these reasons we always want the broker to specify a realm where its
# users live, and we want the users to exist in that realm as well.
$(SASL_DB):
- echo guest | /usr/sbin/saslpasswd2 -c -p -f $(SASL_DB) -u QPID guest
+ echo guest | $(SASL_PASSWD) -c -p -f $(SASL_DB) -u QPID guest
CLEANFILES=$(SASL_DB)