summaryrefslogtreecommitdiff
path: root/extra/foobillard++/PKGBUILD
blob: d57d2bf5da58705bbc691cb2377bc9c611f183b8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# $Id: PKGBUILD 148666 2012-02-05 11:46:13Z ibiru $
# Maintainer: Eric Bélanger <eric@archlinux.org>

pkgname=foobillard++
pkgver=3.42beta
pkgrel=3
pkgdesc="An OpenGL billiard game"
arch=('i686' 'x86_64' 'mips64el')
url="http://foobillardplus.sourceforge.net/"
license=('GPL2')
depends=('freetype2' 'libpng' 'mesa' 'sdl_net' 'sdl_mixer')
replaces=('foobillard')
source=(http://downloads.sourceforge.net/foobillardplus/foobillardplus-${pkgver}.tar.gz)
sha1sums=('51507efab0f595cfff26149003faf669c0a42f32')

build() {
  cd "${srcdir}/foobillardplus-${pkgver}"
  sed -i 's|/opt/foobillardplus/bin/||' foobillardplus.desktop
  sed -i 's|/opt/foobillardplus/||' foobillardplus.desktop
  aclocal --force
  autoconf -f
  autoheader -f
  automake -a -c -f 
  ./configure --prefix=/usr/share
  make
}

package() {
  cd "${srcdir}/foobillardplus-${pkgver}"
  make DESTDIR="${pkgdir}" datadir="${pkgdir}/usr/share/foobillardplus/data" \
    prefix="${pkgdir}/usr/share" install

  install -d "${pkgdir}"/usr/{bin,share/{applications,pixmaps}}
  mv "${pkgdir}"/usr/share/{AUTHORS,COPYING,ChangeLog,INSTALL,README,TODO} "${pkgdir}/usr/share/foobillardplus" 
  mv "${pkgdir}"/usr/share/foobillardplus.desktop "${pkgdir}"/usr/share/applications
  mv "${pkgdir}"/usr/share/foobillardplus.{png,xbm} "${pkgdir}"/usr/share/pixmaps
  ln -s /usr/share/foobillardplus/bin/foobillardplus "${pkgdir}"/usr/bin/foobillardplus
}