summaryrefslogtreecommitdiff
path: root/community-testing/happy/PKGBUILD
blob: 58347172460b62d0a34c1ac9b2493e7819a55396 (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
# $Id: PKGBUILD 77008 2012-10-03 15:23:39Z tdziedzic $
# Maintainer: Thomas Dziedzic <gostrc@gmail.com>
# Contributor: simo <simo@archlinux.org>
# Contributor: Vesa Kaihlavirta <vegai@iki.fi>
 
pkgname=happy
pkgver=1.18.10
pkgrel=1
pkgdesc="The Parser Generator for Haskell"
url="http://hackage.haskell.org/package/happy"
arch=('i686' 'x86_64')
license=("custom:BSD3")
depends=('gmp')
makedepends=('ghc=7.6.1-1' 'haskell-mtl=2.1.2-1')
source=(http://hackage.haskell.org/packages/archive/$pkgname/$pkgver/$pkgname-$pkgver.tar.gz)
md5sums=('a1638e89434427e57f68ef311761dc30')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  # try was deprecated and removed into control.exception
  # we really want tryIOError
  #sed 's/try/&IOError/' -i Setup.lhs

  runhaskell Setup.lhs configure -O --prefix=/usr
  runhaskell Setup.lhs build
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  runhaskell Setup.lhs copy --destdir="${pkgdir}"
  install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}