updated on Mon Jan 23 12:00:23 UTC 2012
[aur-mirror.git] / gogui / PKGBUILD
blobff7407fb790e785a1184463e848c3b142a43728e
1 # Maintainer: solsTiCe d'Hiver <solstice.dhiver@gmail.com>
3 pkgname=gogui
4 pkgver=1.4.0
5 pkgrel=1
6 pkgdesc="a gui for any Go Text Protocol software like GNU Go"
7 arch=(i686 x86_64)
8 url="http://gogui.sourceforge.net"
9 license=("GPL")
10 depends=('java-runtime')
11 source=(http://downloads.sourceforge.net/gogui/gogui-$pkgver.zip)
12 install=gogui.install
13 md5sums=('d59f1a2cfceaaf3c07356ef70670bd00')
15 build() {
16         cd $srcdir/gogui-$pkgver
17         ./install.sh -j $JAVA_HOME -p $pkgdir/usr -s $pkgdir/etc
19         # make it useable with openjdk6 too (NOT TESTED !)
20         sed -i 's|"$JAVA"|java|' $pkgdir/usr/bin/*
22         # fix the installation to remove any ref to $pkgdir in files
23         grep -l -r $pkgdir $pkgdir|while read i
24         do
25                 sed -i 's|'$pkgdir'||' $i
26         done
28         # it does not work with { } and \ on many lines
29         mkdir -p $pkgdir/usr/share/icons/hicolor/48x48/apps
30         mkdir -p $pkgdir/usr/share/icons/hicolor/48x48/mimetypes
31         mkdir -p $pkgdir/usr/share/applications
32         mkdir -p $pkgdir/usr/share/mime/applications
33         mkdir -p $pkgdir/usr/share/mime/packages
34         # .desktop file
35         install -m 644 config/gogui-gogui.desktop $pkgdir/usr/share/applications
36         sed -i 's|gogui-gogui.png|gogui-gogui|' $pkgdir/usr/share/applications/gogui-gogui.desktop
37         install -m 644 config/gogui-gogui.png $pkgdir/usr/share/icons/hicolor/48x48/apps
39         # mime files
40         # i need help here. this does not work because sgf files are already in the shared mime database.
41         install -m 644 config/application-x-go-sgf.png $pkgdir/usr/share/icons/hicolor/48x48/mimetypes
42         install -m 644 config/gogui-mime.xml $pkgdir/usr/share/mime/packages
44         #install -d $pkgdir/usr/share/mimelnk/application
45         #install -m 644 config/x-go-sgf.desktop $pkgdir/usr/share/mimelnk/application