# HG changeset patch # User Pascal Bellard # Date 1349868891 -7200 # Node ID 5fb313d44a9be49230ce854a4ddd828e1b7e97f7 # Parent 44b93d6a30c8abd5abdc7d94e165a412dba1f7a3 Add grooms diff -r 44b93d6a30c8 -r 5fb313d44a9b grooms/receipt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/grooms/receipt Wed Oct 10 13:34:51 2012 +0200 @@ -0,0 +1,63 @@ +# SliTaz package receipt. + +PACKAGE="grooms" +VERSION="1.0.1" +CATEGORY="games" +SHORT_DESC="Play the go game over internet." +MAINTAINER="pascal.bellard@slitaz.org" +WEB_SITE="http://grooms.tuxfamily.org/" +TARBALL="$PACKAGE-$VERSION.zip" +WGET_URL="${WEB_SITE}$TARBALL" + +DEPENDS="php" +BUILD_DEPENDS="" + +# Rules to configure and make the package. +compile_rules() +{ + cd $src +} + +# Rules to gen a SliTaz package suitable for Tazpkg. +genpkg_rules() +{ + mkdir -p $fs/var/lib + cp -a $src $fs/var/lib/grooms +} + +post_install() +{ + # Configure lighttpd server + if [ -f $1/etc/lighttpd/lighttpd.conf ]; then + if ! grep -q /var/lib/grooms $1/etc/lighttpd/lighttpd.conf; then + sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/grooms/" => "/var/lib/grooms/",|g' -i $1/etc/lighttpd/lighttpd.conf + if [ -z "$1" ]; then + # Start Web server. + /etc/init.d/lighttpd stop + /etc/init.d/lighttpd start + fi + fi + fi + # Configure apache server + if [ -f $1/etc/apache/httpd.conf ]; then + if [ ! -f $1/etc/apache/conf.d/grooms ]; then + cat > $1/etc/apache/conf.d/grooms < + Alias /grooms /var/lib/grooms + + + DirectoryIndex index.php + Options +FollowSymLinks + AllowOverride None + Order allow,deny + Allow from all + +EOT + if [ -z "$1" ]; then + # Start Web server. + /etc/init.d/apache stop + /etc/init.d/apache start + fi + fi + fi +}