summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--package/openldap/Config.in12
-rw-r--r--package/openldap/openldap.mk12
2 files changed, 24 insertions, 0 deletions
diff --git a/package/openldap/Config.in b/package/openldap/Config.in
index 1f0b1eabc3..3085a5c87e 100644
--- a/package/openldap/Config.in
+++ b/package/openldap/Config.in
@@ -10,6 +10,18 @@ config BR2_PACKAGE_OPENLDAP
http://www.openldap.org/
+if BR2_PACKAGE_OPENLDAP
+
+config BR2_PACKAGE_OPENLDAP_CLIENTS
+ bool "openldap client binaries"
+ default y
+ help
+ Install the OpenLDAP client tools (ldapadd, ldapcompare, ldapdelete,
+ ldapexop, ldapmodify, ldapmodrdn, ldappasswd, ldapsearch, ldapurl,
+ ldapwhoami)
+
+endif
+
comment "openldap needs a toolchain w/ wchar"
depends on BR2_USE_MMU # needs fork()
depends on !BR2_USE_WCHAR
diff --git a/package/openldap/openldap.mk b/package/openldap/openldap.mk
index 332b2c4ddf..991d36953f 100644
--- a/package/openldap/openldap.mk
+++ b/package/openldap/openldap.mk
@@ -55,4 +55,16 @@ OPENLDAP_CONF_OPTS += \
# executable it is supposed to install, resulting in an error.
OPENLDAP_MAKE_ENV = STRIP="$(TARGET_STRIP)"
+ifeq ($(BR2_PACKAGE_OPENLDAP_CLIENTS),)
+OPENLDAP_CLIENTS = \
+ ldapurl ldapexop ldapcompare ldapwhoami \
+ ldappasswd ldapmodrdn ldapdelete ldapmodify \
+ ldapsearch
+define OPENLDAP_REMOVE_CLIENTS
+ $(RM) -f $(foreach p,$(OPENLDAP_CLIENTS),$(TARGET_DIR)/usr/bin/$(p))
+ $(RM) -rf $(TARGET_DIR)/etc/openldap
+endef
+OPENLDAP_POST_INSTALL_TARGET_HOOKS += OPENLDAP_REMOVE_CLIENTS
+endif
+
$(eval $(autotools-package))
OpenPOWER on IntegriCloud