updated on Thu Jan 19 20:01:47 UTC 2012
[aur-mirror.git] / haskell-repa / PKGBUILD
blob99ca77660c8b352678d81a36b313eb620e03af83
1 # custom variables
2 _hkgname=repa
3 _licensefile=LICENSE
5 # PKGBUILD options/directives
6 pkgname=haskell-repa
7 pkgver=2.1.1.5
8 pkgrel=2
9 pkgdesc="High performance, regular, shape polymorphic parallel arrays."
10 url="http://repa.ouroborus.net"
11 license=("BSD3")
12 arch=('i686' 'x86_64')
13 makedepends=()
14 depends=("ghc=7.0.3-2"
15          "haskell-quickcheck=2.4.0.1-3.1"
16          "haskell-vector=0.9-1")
17 options=('strip')
18 source=("http://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz"
19         "cabal.patch")
20 install="${pkgname}.install"
21 sha256sums=("2599d336c26b7eb7c722490b2bbfdfe3a447b6d7fdc2c050ba4a7717b5359892"
22             "24a6fca69405a7943aa3b851510232a29caa559556621e1ce806211e88b9758c")
24 # PKGBUILD functions
25 build() {
26     cd ${srcdir}/${_hkgname}-${pkgver}
27     patch repa.cabal ${srcdir}/cabal.patch 
28     runhaskell Setup configure -O -p --enable-split-objs --enable-shared \
29         --prefix=/usr --docdir=/usr/share/doc/${pkgname} \
30         --libsubdir=\$compiler/site-local/\$pkgid
31     runhaskell Setup build
32     runhaskell Setup haddock
33     runhaskell Setup register --gen-script
34     runhaskell Setup unregister --gen-script
35     sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
38 package() {
39     cd ${srcdir}/${_hkgname}-${pkgver}
40     install -D -m744 register.sh   ${pkgdir}/usr/share/haskell/${pkgname}/register.sh
41     install    -m744 unregister.sh ${pkgdir}/usr/share/haskell/${pkgname}/unregister.sh
42     install -d -m755 ${pkgdir}/usr/share/doc/ghc/html/libraries
43     ln -s /usr/share/doc/${pkgname}/html ${pkgdir}/usr/share/doc/ghc/html/libraries/${_hkgname}
44     runhaskell Setup copy --destdir=${pkgdir}
45     install -D -m644 ${_licensefile} ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
46     rm -f ${pkgdir}/usr/share/doc/${pkgname}/${_licensefile}