wok-current annotate phpldapadmin/receipt @ rev 1212
Add missing CONFIG_FILES=
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Aug 09 17:50:04 2008 +0000 (2008-08-09) |
parents | c13c815a576c |
children | 6bfa3b761dd2 |
rev | line source |
---|---|
pascal@1155 | 1 # SliTaz package receipt. |
pascal@1155 | 2 |
pascal@1155 | 3 PACKAGE="phpldapadmin" |
pascal@1155 | 4 VERSION="1.1.0.5" |
pascal@1155 | 5 CATEGORY="misc" |
pascal@1155 | 6 SHORT_DESC="Administration of LDAP over the Web." |
pascal@1155 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@1155 | 8 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@1155 | 9 WEB_SITE="http://$PACKAGE.sourceforge.net/" |
pascal@1155 | 10 WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL" |
pascal@1155 | 11 DEPENDS="php-ldap" |
pascal@1212 | 12 CONFIG_FILES="/etc/phpldapadmin/config.php" |
pascal@1155 | 13 |
pascal@1155 | 14 # Rules to configure and make the package. |
pascal@1155 | 15 compile_rules() |
pascal@1155 | 16 { |
pascal@1155 | 17 echo "$src compiled..." |
pascal@1155 | 18 } |
pascal@1155 | 19 |
pascal@1155 | 20 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1155 | 21 genpkg_rules() |
pascal@1155 | 22 { |
pascal@1155 | 23 mkdir -p $fs/usr/share/phpldapadmin $fs/etc |
pascal@1155 | 24 cp -a $src/. $fs/usr/share/phpldapadmin |
pascal@1155 | 25 mv $fs/usr/share/phpldapadmin/config $fs/etc/phpldapadmin |
pascal@1155 | 26 ln -s /etc/phpldapadmin $fs/usr/share/phpldapadmin/config |
pascal@1155 | 27 mv $fs/etc/phpldapadmin/config.php.example $fs/etc/phpldapadmin/config.php |
pascal@1155 | 28 chown -R www.www $fs/usr/share/phpldapadmin $fs/etc/phpldapadmin |
pascal@1155 | 29 chmod 700 $fs/etc/phpldapadmin |
pascal@1155 | 30 chmod 600 $fs/etc/phpldapadmin/config.php |
pascal@1155 | 31 } |
pascal@1155 | 32 |
pascal@1155 | 33 post_install() |
pascal@1155 | 34 { |
pascal@1155 | 35 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \ |
pascal@1155 | 36 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOT |
pascal@1155 | 37 etc/phpldapadmin/config.php |
pascal@1155 | 38 EOT |
pascal@1155 | 39 if [ -f $1/etc/lighttpd/lighttpd.conf ]; then |
pascal@1155 | 40 if ! grep -q /usr/share/phpldapadmin/ $1/etc/lighttpd/lighttpd.conf; then |
pascal@1155 | 41 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/phpldapadmin/" => "/usr/share/phpldapadmin/",|g' -i $1/etc/lighttpd/lighttpd.conf |
pascal@1155 | 42 if [ -z "$1" ]; then |
pascal@1155 | 43 # Start Web server. |
pascal@1155 | 44 /etc/init.d/lighttpd stop |
pascal@1155 | 45 /etc/init.d/lighttpd start |
pascal@1155 | 46 fi |
pascal@1155 | 47 fi |
pascal@1155 | 48 fi |
pascal@1155 | 49 } |
pascal@1155 | 50 |
pascal@1155 | 51 repack_cleanup() |
pascal@1155 | 52 { |
pascal@1155 | 53 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id ) |
pascal@1155 | 54 } |