summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Slebodnik <lslebodn@redhat.com>2017-05-30 14:40:07 +0200
committerLukas Slebodnik <lslebodn@redhat.com>2017-05-31 15:24:12 +0200
commit8ccc9b7c317cf5ee8f295b38bfc4c2b7d551f8f1 (patch)
tree5ad8db49a3409fc212f342367da918a36d4de0a5
parent074ded4cda2ce88563a3e7e5cc0eea808d3322b3 (diff)
downloadsssd-8ccc9b7c317cf5ee8f295b38bfc4c2b7d551f8f1.tar.gz
sssd-8ccc9b7c317cf5ee8f295b38bfc4c2b7d551f8f1.tar.xz
sssd-8ccc9b7c317cf5ee8f295b38bfc4c2b7d551f8f1.zip
BUILD: Improve error messages for optional dependencies
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
-rw-r--r--configure.ac2
-rw-r--r--contrib/sssd.spec.in6
-rw-r--r--src/external/libcurl.m46
-rw-r--r--src/external/libjansson.m45
4 files changed, 14 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac
index 80d8ea9ff..e8fe1d47e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -197,7 +197,6 @@ m4_include([src/external/service.m4])
if test x$with_secrets = xyes; then
m4_include([src/external/libhttp_parser.m4])
- m4_include([src/external/libjansson.m4])
fi
if test x$with_kcm = xyes; then
@@ -206,6 +205,7 @@ fi
if test x$with_kcm = xyes -o x$with_secrets = xyes; then
m4_include([src/external/libcurl.m4])
+ m4_include([src/external/libjansson.m4])
fi
# This variable is defined by external/libcurl.m4, but conditionals
diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index faae80e40..fb175ae7a 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -224,10 +224,14 @@ BuildRequires: systemtap-sdt-devel
%endif
%if (0%{?with_secrets} == 1)
BuildRequires: http-parser-devel
-BuildRequires: jansson-devel
%endif
+%if (0%{?with_kcm} == 1)
BuildRequires: libuuid-devel
+%endif
+%if (0%{?with_secrets} == 1 || 0%{?with_kcm} == 1)
+BuildRequires: jansson-devel
BuildRequires: libcurl-devel
+%endif
%description
Provides a set of daemons to manage access to remote directories and
diff --git a/src/external/libcurl.m4 b/src/external/libcurl.m4
index 42be308cd..94cea9ebe 100644
--- a/src/external/libcurl.m4
+++ b/src/external/libcurl.m4
@@ -1,5 +1,9 @@
PKG_CHECK_MODULES([CURL], [libcurl], [found_libcurl=yes],
- [AC_MSG_ERROR([The libcurl development library was not found.])])
+ [AC_MSG_ERROR([The libcurl development library was not found.
+You must have the header file curl/curl.h installed to build sssd
+with secrets and KCM responder. If you want to build sssd without these
+responders then specify --without-secrets --without-kcm when running configure.
+])])
AS_IF([test x"$found_libcurl" = xyes],
CFLAGS="$CFLAGS $CURL_CFLAGS"
diff --git a/src/external/libjansson.m4 b/src/external/libjansson.m4
index 48a4a5fd8..d87769848 100644
--- a/src/external/libjansson.m4
+++ b/src/external/libjansson.m4
@@ -13,5 +13,6 @@ AS_IF([test x"$found_jansson" != xyes],
[-L$sss_extra_libdir -ljanson])],
[AC_MSG_ERROR([
You must have the header file jansson.h installed to build sssd
-with secrets responder. If you want to build sssd without secret responder
-then specify --without-secrets when running configure.])])])
+with secrets and KCM responder. If you want to build sssd without these
+responders then specify --without-secrets --without-kcm when running configure.
+])])])