wok-next view othello/receipt @ rev 15602
Use DESTDIR
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Dec 05 20:42:36 2013 +0000 (2013-12-05) |
parents | c2e7ccf93d10 |
children | f13bd223c231 |
line source
1 # SliTaz package receipt.
3 PACKAGE="othello"
4 VERSION="1.0"
5 CATEGORY="games"
6 SHORT_DESC="Othello game in javascript"
7 TARBALL="$PACKAGE-$VERSION.tar.lzma"
8 MAINTAINER="pascal.bellard@slitaz.org"
9 WEB_SITE="http://www.posi.net/software/othello/"
11 # Rules to configure and make the package.
12 compile_rules()
13 {
14 mkdir -p $src/images 2> /dev/null
15 cd $src
16 if [ ! -s othello.js ]; then
17 if [ -f $SOURCES_REPOSITORY/$TARBALL ]; then
18 unlzma -c $SOURCES_REPOSITORY/$TARBALL | tar xf -
19 mv $PACKAGE-$VERSION/* .
20 else
21 wget -O $SOURCES_REPOSITORY/$TARBALL http://mirror.slitaz.org/sources/packages/o/$TARBALL &&
22 unlzma -c $SOURCES_REPOSITORY/$TARBALL | tar xf -
23 mv $PACKAGE-$VERSION/* .
24 fi
25 fi
26 #for i in index.html othello.js \
27 # images/blank.gif images/white.gif images/black.gif \
28 # images/white-trans.gif images/black-trans.gif ; do
29 # [ -s $i ] || wget -P $(dirname $i) $WEB_SITE/$i
30 #done
31 sed -i 's|TITLE>.*</TITLE|TITLE>Othello</TITLE|' index.html
32 }
34 # Rules to gen a SliTaz package suitable for Tazpkg.
35 genpkg_rules()
36 {
37 mkdir -p $fs/var/www/othello $fs/usr/share/applications
38 cp -a $src/* $fs/var/www/othello
39 chown -R 80.80 $fs/var/www/othello
40 cat > $fs/usr/share/applications/othello.desktop <<EOT
41 [Desktop Entry]
42 Type=Application
43 Name=Othello
44 Exec=browser file:///var/www/othello/index.html
45 Icon=/var/www/othello/images/black.gif
46 Terminal=false
47 Categories=Game;
48 Comment=Othello game
49 EOT
50 }