############################################################################### # IPFire.org - An Open Source Firewall Solution # # Copyright (C) - IPFire Development Team # ############################################################################### name = nss_ldap version = 265 release = 5 groups = System/Base url = http://www.padl.com/ license = LGPLv2+ summary = NSS library and PAM module for LDAP. description This package includes two LDAP access clients: nss_ldap and pam_ldap. Nss_ldap is a set of C library extensions that allow X.500 and LDAP directory servers to be used as a primary source of aliases, ethers, groups, hosts, networks, protocol, users, RPCs, services, and shadow passwords. end source_dl = http://www.padl.com/download/ patches = \ nss_ldap-265-depth.patch \ nss_ldap-254-soname.patch \ nss_ldap-257-mozldap.patch \ nss_ldap-259-res_init.patch \ nss_ldap-264-checkcase.patch \ nss_ldap-265-ent_internal.patch \ nss_ldap-264-cloexec.patch \ nss_ldap-265-local_users.patch \ nss_ldap-265-erange.patch \ nss_ldap-265-initgroups-minimum_uid.patch \ nss_ldap-265-fix-uninit.patch \ nss_ldap-265-padl-bug-418.patch \ nss_ldap-265-setnetgrent.patch build requires autoconf automake cyrus-sasl-devel openldap-devel end configure_options += \ --sysconfdir=/etc \ --with-ldap-lib=openldap \ --enable-rfc2307bis \ --with-ldap-conf-file=/etc/nss_ldap.conf \ --with-ldap-secret-file=/etc/nss_ldap.secret prepare_cmds sed -i -e 's,^ldap.conf$$,nss_ldap.conf,g' *.5 sed -i -e 's,^/etc/ldap\.,/etc/nss_ldap.,g' *.5 sed -i -e 's,ldap.secret,nss_ldap.secret,g' *.5 sed -i -e 's,(ldap.conf),(nss_ldap.conf),g' *.5 # Fix call for vers_string. sed -e "s/vers_string/.\/&/g" -i Makefile* autoreconf -vfi end make_build_targets += \ LDFLAGS="-Wl,-z,nodelete" make_install_targets += \ LIBC_VERS=%{version} install_cmds # Remove awkward directory rm -rvf %{BUILDROOT}/usr/usr if [ -e "%{BUILDROOT}%{libdir}/libnss_ldap-%{version}.so" ]; then ln -svf libnss_ldap-%{version}.so %{BUILDROOT}%{libdir}/libnss_ldap.so.2 ln -svf libnss_ldap.so.2 %{BUILDROOT}%{libdir}/libnss_ldap.so fi rm -vf %{BUILDROOT}/etc/nsswitch.ldap cd %{DIR_APP} && sed 's|dc=padl|dc=example|g' ldap.conf > \ %{BUILDROOT}/etc/nss_ldap.conf touch %{BUILDROOT}/etc/nss_ldap.secret end end packages package %{name} requires %{libdir}/security/pam_ldap.so end configfiles %{sysconfdir}/nss_ldap.conf %{sysconfdir}/nss_ldap.secret end end package %{name}-debuginfo template DEBUGINFO end end