wok-6.x annotate nss_ldap/receipt @ rev 10718
Up: slitaz-tools (4.2.1) - Bug fix and tazx support UK keyboard
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Sat May 28 23:32:40 2011 +0200 (2011-05-28) |
parents | d3bc17858374 |
children | 8e4c74abdf74 |
rev | line source |
---|---|
pascal@1946 | 1 # SliTaz package receipt. |
pascal@1946 | 2 |
pascal@1946 | 3 PACKAGE="nss_ldap" |
pascal@5792 | 4 VERSION="265" |
pascal@1946 | 5 CATEGORY="system-tools" |
pascal@1946 | 6 SHORT_DESC="Get users, hosts, and groups from LDAP." |
pascal@1946 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@5808 | 8 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@5004 | 9 DEPENDS="cyrus-sasl libkrb5 libldap openssl libcomerr libcomerr3" |
slaxemulator@8375 | 10 BUILD_DEPENDS="openldap-dev" |
pascal@1946 | 11 WEB_SITE="http://www.padl.com/OSS/nss_ldap.html" |
pascal@1946 | 12 WGET_URL="http://www.padl.com/download/$TARBALL" |
pascal@1946 | 13 |
pascal@1946 | 14 # Rules to configure and make the package. |
pascal@1946 | 15 compile_rules() |
pascal@1946 | 16 { |
pascal@1946 | 17 cd $src |
pascal@5880 | 18 ./vers_string -v |
pascal@1946 | 19 ./configure --prefix=/usr --infodir=/usr/share/info \ |
pascal@2453 | 20 --enable-rfc2307bis --enable-schema-mapping --enable-paged-results \ |
pascal@1946 | 21 --sysconfdir=/etc --mandir=/usr/share/man $CONFIGURE_ARGS && |
pascal@5808 | 22 make -j 4 && |
pascal@1946 | 23 make DESTDIR=$PWD/_pkg install |
pascal@1946 | 24 } |
pascal@1946 | 25 |
pascal@1946 | 26 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1946 | 27 genpkg_rules() |
pascal@1946 | 28 { |
pascal@1946 | 29 mkdir -p $fs/usr $fs/etc |
pascal@1946 | 30 cp -a $_pkg/usr/lib $fs/usr |
pascal@1946 | 31 cp -a $_pkg/etc $fs |
pascal@1946 | 32 } |
pascal@1946 | 33 |
pascal@1946 | 34 post_install() |
pascal@1946 | 35 { |
pascal@1946 | 36 if [ -s $1/etc/openldap/slapd.conf ]; then |
pascal@1946 | 37 suffix=$(awk '/^suffix/ { print $2 }' < $1/etc/openldap/slapd.conf | sed 's/"//g') |
pascal@1946 | 38 rootdn=$(awk '/^rootdn/ { print $2 }' < $1/etc/openldap/slapd.conf | sed 's/"//g') |
pascal@1946 | 39 rootpw=$(awk '/^rootpw/ { print $2 }' < $1/etc/openldap/slapd.conf) |
pascal@2532 | 40 sed -i -e "s|binddn .*|binddn $rootdn|" \ |
pascal@2532 | 41 -e "s|bindpw .*|bindpw $rootpw|" \ |
pascal@2532 | 42 -e "s|dc=padl,dc=com|$suffix|g" $1/etc/ldap.conf |
pascal@1946 | 43 cat <<EOT |
pascal@1946 | 44 ------ |
pascal@1946 | 45 Suffix login DN and password are found in /etc/openldap/slapd.conf with suffix, rootdn and rootpw keywords: |
pascal@1946 | 46 $(grep ^suffix /etc/openldap/slapd.conf) |
pascal@1946 | 47 $(grep ^rootdn /etc/openldap/slapd.conf) |
pascal@1946 | 48 $(grep ^rootpw /etc/openldap/slapd.conf) |
pascal@1946 | 49 ------ |
pascal@1946 | 50 EOT |
pascal@1946 | 51 fi |
pascal@1946 | 52 } |