Created
November 24, 2014 21:01
-
-
Save wilbowma/0ae071c31ba3252d5e37 to your computer and use it in GitHub Desktop.
Updated haskell-cpphs PKGBUILD
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # custom variables | |
| _hkgname=cpphs | |
| _licensefile=LICENSE | |
| # PKGBUILD options/directives | |
| pkgname=haskell-cpphs | |
| pkgver=1.18.6 | |
| pkgrel=1 | |
| pkgdesc="Cpphs is a re-implementation of the C pre-processor that is both more compatible with Haskell." | |
| url="http://hackage.haskell.org/package/${_hkgname}" | |
| license=("LGPL") | |
| arch=('i686' 'x86_64') | |
| makedepends=() | |
| depends=("ghc") | |
| source=("http://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") | |
| install=$pkgname.install | |
| sha256sums=('ac3f120aaa4d9982f8a2e63826a40b3413ed853bf04bca86e3fac5a5be084737') | |
| # PKGBUILD functions | |
| build() { | |
| cd ${srcdir}/${_hkgname}-${pkgver} | |
| runhaskell Setup configure -O \ | |
| ${PKGBUILD_HASKELL_ENABLE_PROFILING:+-p }\ | |
| --enable-split-objs \ | |
| --enable-shared \ | |
| --prefix=/usr \ | |
| --docdir=/usr/share/doc/${pkgname} \ | |
| --libsubdir=\$compiler/site-local/\$pkgid | |
| runhaskell Setup build | |
| runhaskell Setup haddock | |
| runhaskell Setup register --gen-script | |
| runhaskell Setup unregister --gen-script | |
| sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh | |
| } | |
| package() { | |
| cd ${srcdir}/${_hkgname}-${pkgver} | |
| install -D -m744 register.sh ${pkgdir}/usr/share/haskell/${pkgname}/register.sh | |
| install -m744 unregister.sh ${pkgdir}/usr/share/haskell/${pkgname}/unregister.sh | |
| install -d -m755 ${pkgdir}/usr/share/doc/ghc/html/libraries | |
| ln -s /usr/share/doc/${pkgname}/html ${pkgdir}/usr/share/doc/ghc/html/libraries/${_hkgname} | |
| runhaskell Setup copy --destdir=${pkgdir} | |
| rm -f ${pkgdir}/usr/share/doc/${pkgname}/${_licensefile} | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment