]> Git Repo - buildroot-mgba.git/blob - package/openldap/openldap.mk
package/cmake: bump to 3.30.2
[buildroot-mgba.git] / package / openldap / openldap.mk
1 ################################################################################
2 #
3 # openldap
4 #
5 ################################################################################
6
7 OPENLDAP_VERSION = 2.5.18
8 OPENLDAP_SOURCE = openldap-$(OPENLDAP_VERSION).tgz
9 OPENLDAP_SITE = https://www.openldap.org/software/download/OpenLDAP/openldap-release
10 OPENLDAP_LICENSE = OpenLDAP Public License
11 OPENLDAP_LICENSE_FILES = LICENSE
12 OPENLDAP_CPE_ID_VENDOR = openldap
13 OPENLDAP_SELINUX_MODULES = ldap
14 OPENLDAP_INSTALL_STAGING = YES
15 OPENLDAP_DEPENDENCIES = host-pkgconf
16
17 ifeq ($(BR2_PACKAGE_OPENSSL),y)
18 OPENLDAP_TLS = openssl
19 OPENLDAP_DEPENDENCIES += openssl
20 else ifeq ($(BR2_PACKAGE_GNUTLS),y)
21 OPENLDAP_TLS = gnutls
22 OPENLDAP_DEPENDENCIES += gnutls
23 else ifeq ($(BR2_PACKAGE_LIBNSS),y)
24 OPENLDAP_TLS = moznss
25 OPENLDAP_DEPENDENCIES += libnss
26 OPENLDAP_CPPFLAGS = \
27         -I$(STAGING_DIR)/usr/include/nss \
28         -I$(STAGING_DIR)/usr/include/nspr
29 else
30 OPENLDAP_TLS = no
31 endif
32
33 ifeq ($(BR2_PACKAGE_OPENSSL),y)
34 OPENLDAP_MP = bignum
35 OPENLDAP_DEPENDENCIES += openssl
36 OPENLDAP_CONF_ENV = LIBS="`$(PKG_CONFIG_HOST_BINARY) --libs libssl libcrypto`"
37 else ifeq ($(BR2_PACKAGE_GMP),y)
38 OPENLDAP_MP = gmp
39 OPENLDAP_DEPENDENCIES += gmp
40 else
41 OPENLDAP_MP = longlong
42 endif
43
44 OPENLDAP_CONF_ENV += ac_cv_func_memcmp_working=yes
45
46 OPENLDAP_CONF_OPTS += \
47         --enable-syslog \
48         --disable-proctitle \
49         --disable-slapd \
50         --with-yielding-select \
51         --sysconfdir=/etc \
52         --enable-dynamic=$(if $(BR2_STATIC_LIBS),no,yes) \
53         --with-tls=$(OPENLDAP_TLS) \
54         --with-mp=$(OPENLDAP_MP) \
55         CPPFLAGS="$(TARGET_CPPFLAGS) $(OPENLDAP_CPPFLAGS)"
56
57 # Somehow, ${STRIP} does not percolates through to the shtool script
58 # used to install the executables; thus, that script tries to run the
59 # executable it is supposed to install, resulting in an error.
60 OPENLDAP_MAKE_ENV = STRIP="$(TARGET_STRIP)"
61
62 ifeq ($(BR2_PACKAGE_OPENLDAP_CLIENTS),)
63 OPENLDAP_CLIENTS = \
64         ldapurl ldapexop ldapcompare ldapwhoami \
65         ldappasswd ldapmodrdn ldapdelete ldapmodify \
66         ldapsearch
67 define OPENLDAP_REMOVE_CLIENTS
68         $(RM) -f $(foreach p,$(OPENLDAP_CLIENTS),$(TARGET_DIR)/usr/bin/$(p))
69         $(RM) -rf $(TARGET_DIR)/etc/openldap
70 endef
71 OPENLDAP_POST_INSTALL_TARGET_HOOKS += OPENLDAP_REMOVE_CLIENTS
72 endif
73
74 $(eval $(autotools-package))
This page took 0.030689 seconds and 4 git commands to generate.