wok-6.x annotate grooms/receipt @ rev 14310
Up: elementary (1.7.5)
author | Dominique Corbex <domcox@slitaz.org> |
---|---|
date | Sun Apr 07 10:22:40 2013 +0200 (2013-04-07) |
parents | 715718b84344 |
children | 7bb096863642 |
rev | line source |
---|---|
pascal@13478 | 1 # SliTaz package receipt. |
pascal@13478 | 2 |
pascal@13478 | 3 PACKAGE="grooms" |
samuel_trassare@13680 | 4 VERSION="1.0.5" |
pascal@13478 | 5 CATEGORY="games" |
samuel_trassare@13680 | 6 SHORT_DESC="Play the board game, Go, over the Internet." |
pascal@13478 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
samuel_trassare@13680 | 8 WEB_SITE="http://$PACKAGE.tuxfamily.org" |
pascal@13478 | 9 TARBALL="$PACKAGE-$VERSION.zip" |
samuel_trassare@13680 | 10 WGET_URL="${WEB_SITE}/$TARBALL" |
pascal@13478 | 11 |
pascal@13478 | 12 DEPENDS="php" |
pascal@13478 | 13 |
pascal@13478 | 14 # Rules to configure and make the package. |
pascal@13478 | 15 compile_rules() |
pascal@13478 | 16 { |
pascal@13478 | 17 cd $src |
pascal@13478 | 18 } |
pascal@13478 | 19 |
pascal@13478 | 20 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@13478 | 21 genpkg_rules() |
pascal@13478 | 22 { |
pascal@13478 | 23 mkdir -p $fs/var/lib |
pascal@13478 | 24 cp -a $src $fs/var/lib/grooms |
pascal@13479 | 25 chown 80.80 $fs/var/lib/grooms |
pascal@13478 | 26 } |
pascal@13478 | 27 |
pascal@13478 | 28 post_install() |
pascal@13478 | 29 { |
pascal@13478 | 30 # Configure lighttpd server |
pascal@13478 | 31 if [ -f $1/etc/lighttpd/lighttpd.conf ]; then |
pascal@13478 | 32 if ! grep -q /var/lib/grooms $1/etc/lighttpd/lighttpd.conf; then |
pascal@13478 | 33 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/grooms/" => "/var/lib/grooms/",|g' -i $1/etc/lighttpd/lighttpd.conf |
pascal@13478 | 34 if [ -z "$1" ]; then |
pascal@13478 | 35 # Start Web server. |
pascal@13478 | 36 /etc/init.d/lighttpd stop |
pascal@13478 | 37 /etc/init.d/lighttpd start |
pascal@13478 | 38 fi |
pascal@13478 | 39 fi |
pascal@13478 | 40 fi |
pascal@13478 | 41 # Configure apache server |
pascal@13478 | 42 if [ -f $1/etc/apache/httpd.conf ]; then |
pascal@13478 | 43 if [ ! -f $1/etc/apache/conf.d/grooms ]; then |
pascal@13478 | 44 cat > $1/etc/apache/conf.d/grooms <<EOT |
pascal@13478 | 45 <IfModule mod_alias.c> |
pascal@13478 | 46 Alias /grooms /var/lib/grooms |
pascal@13478 | 47 </IfModule> |
pascal@13478 | 48 <Directory /var/lib/grooms/> |
pascal@13478 | 49 DirectoryIndex index.php |
pascal@13478 | 50 Options +FollowSymLinks |
pascal@13478 | 51 AllowOverride None |
pascal@13478 | 52 Order allow,deny |
pascal@13478 | 53 Allow from all |
pascal@13478 | 54 </Directory> |
pascal@13478 | 55 EOT |
pascal@13478 | 56 if [ -z "$1" ]; then |
pascal@13478 | 57 # Start Web server. |
pascal@13478 | 58 /etc/init.d/apache stop |
pascal@13478 | 59 /etc/init.d/apache start |
pascal@13478 | 60 fi |
pascal@13478 | 61 fi |
pascal@13478 | 62 fi |
pascal@13478 | 63 } |