updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / haskell-http-enumerator / PKGBUILD
blob16ca977f14b67e69828ecadf63d0d6ef39743226
1 # custom variables
2 _hkgname=http-enumerator
3 _licensefile=LICENSE
5 # PKGBUILD options/directives
6 pkgname=haskell-http-enumerator
7 pkgver=0.7.0
8 pkgrel=6
9 pkgdesc="HTTP client package with enumerator interface and HTTPS support."
10 url="http://github.com/snoyberg/http-enumerator"
11 license=("BSD3")
12 arch=('i686' 'x86_64')
13 makedepends=()
14 depends=("ghc=7.0.3-2"
15          "haskell-asn1-data=0.5.1-23"
16          "haskell-attoparsec=0.9.1.2-1"
17          "haskell-attoparsec-enumerator=0.2.0.4-23"
18          "haskell-base64-bytestring=0.1.0.3-1"
19          "haskell-blaze-builder=0.3.0.1-18"
20          "haskell-blaze-builder-enumerator=0.2.0.3-2"
21          "haskell-case-insensitive=0.3.0.1-2"
22          "haskell-certificate=0.9.1-5"
23          "haskell-cprng-aes=0.2.1-24"
24          "haskell-data-default=0.3.0-1"
25          "haskell-enumerator=0.4.15-1"
26          "haskell-failure=0.1.0.1-18"
27          "haskell-http-types=0.6.6-1"
28          "haskell-monad-control=0.2.0.3-2"
29          "haskell-network=2.3.0.2-2.1"
30          "haskell-tls=0.7.2-6"
31          "haskell-tls-extra=0.3.1-6"
32          "haskell-transformers=0.2.2.0-3.1"
33          "haskell-utf8-string=0.3.6-7.2"
34          "haskell-zlib-enum=0.2.1-23")
35 options=('strip')
36 source=("http://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz")
37 install="${pkgname}.install"
38 sha256sums=("ff2a5673b48e34734a452560b5306d45bef52e02ad0cd892533579b4ff007941")
40 # PKGBUILD functions
41 build() {
42     cd ${srcdir}/${_hkgname}-${pkgver}
43     
44     runhaskell Setup configure -O -p --enable-split-objs --enable-shared \
45         --prefix=/usr --docdir=/usr/share/doc/${pkgname} \
46         --libsubdir=\$compiler/site-local/\$pkgid
47     runhaskell Setup build
48     runhaskell Setup haddock
49     runhaskell Setup register --gen-script
50     runhaskell Setup unregister --gen-script
51     sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
54 package() {
55     cd ${srcdir}/${_hkgname}-${pkgver}
56     install -D -m744 register.sh   ${pkgdir}/usr/share/haskell/${pkgname}/register.sh
57     install    -m744 unregister.sh ${pkgdir}/usr/share/haskell/${pkgname}/unregister.sh
58     install -d -m755 ${pkgdir}/usr/share/doc/ghc/html/libraries
59     ln -s /usr/share/doc/${pkgname}/html ${pkgdir}/usr/share/doc/ghc/html/libraries/${_hkgname}
60     runhaskell Setup copy --destdir=${pkgdir}
61     install -D -m644 ${_licensefile} ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
62     rm -f ${pkgdir}/usr/share/doc/${pkgname}/${_licensefile}