[arch-commits] Commit in (5 files)
Felix Yan
felixonmars at archlinux.org
Mon Feb 6 05:51:51 UTC 2017
Date: Monday, February 6, 2017 @ 05:51:51
Author: felixonmars
Revision: 210277
addpkg: haskell-skylighting 0.1.1.5-1
Added:
haskell-skylighting/
haskell-skylighting/repos/
haskell-skylighting/trunk/
haskell-skylighting/trunk/PKGBUILD
haskell-skylighting/trunk/system-pcre.patch
-------------------+
PKGBUILD | 49 ++++++++++++++++++++++++++++++++++++++++++++
system-pcre.patch | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 106 insertions(+)
Added: haskell-skylighting/trunk/PKGBUILD
===================================================================
--- haskell-skylighting/trunk/PKGBUILD (rev 0)
+++ haskell-skylighting/trunk/PKGBUILD 2017-02-06 05:51:51 UTC (rev 210277)
@@ -0,0 +1,49 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=skylighting
+pkgname=haskell-skylighting
+pkgver=0.1.1.5
+pkgrel=1
+pkgdesc="Syntax highlighting library"
+url="https://github.com/jgm/skylighting"
+license=('GPL2')
+arch=('i686' 'x86_64')
+depends=('ghc=8.0.1' 'haskell-aeson' 'haskell-blaze-html' 'haskell-case-insensitive' 'haskell-hxt'
+ 'haskell-mtl' 'haskell-pretty-show' 'haskell-regex-pcre' 'haskell-safe' 'haskell-text'
+ 'haskell-utf8-string')
+source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz"
+ system-pcre.patch)
+md5sums=('7681c510ab20d79a32a0a54479a2325c'
+ '5971978a26d8133df62b803bd67a70b6')
+
+prepare() {
+ cd "${srcdir}/${_hkgname}-${pkgver}"
+ patch -p1 -i ../system-pcre.patch
+}
+
+build() {
+ cd "${srcdir}/${_hkgname}-${pkgver}"
+
+ runhaskell Setup configure -O --enable-library-profiling --enable-shared \
+ --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+ --libsubdir=\$compiler/site-local/\$pkgid \
+ -fsystem-pcre
+ runhaskell Setup build
+ runhaskell Setup haddock --hoogle --html
+ runhaskell Setup register --gen-script
+ runhaskell Setup unregister --gen-script
+ sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh
+ 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/register/${pkgname}.sh"
+ install -D -m744 unregister.sh "${pkgdir}/usr/share/haskell/unregister/${pkgname}.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}/LICENSE"
+}
Property changes on: haskell-skylighting/trunk/PKGBUILD
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Added: haskell-skylighting/trunk/system-pcre.patch
===================================================================
--- haskell-skylighting/trunk/system-pcre.patch (rev 0)
+++ haskell-skylighting/trunk/system-pcre.patch 2017-02-06 05:51:51 UTC (rev 210277)
@@ -0,0 +1,57 @@
+commit 5fbf9b74c1d34a395a99e61349e3f5f8af0f6140
+Author: Felix Yan <felixonmars at archlinux.org>
+Date: Mon Feb 6 11:44:37 2017 +0800
+
+ Add a flag to build with system pcre
+
+diff --git a/skylighting.cabal b/skylighting.cabal
+index 83d39aa..f5684bf 100644
+--- a/skylighting.cabal
++++ b/skylighting.cabal
+@@ -228,7 +228,6 @@ library
+ mtl,
+ text,
+ bytestring,
+- regex-pcre-builtin,
+ directory,
+ filepath,
+ aeson,
+@@ -238,6 +237,10 @@ library
+ safe,
+ blaze-html >= 0.5,
+ containers
++ if flag(system-pcre)
++ build-depends: regex-pcre
++ else
++ build-depends: regex-pcre-builtin
+ hs-source-dirs: src
+ if impl(ghc < 7.10)
+ hs-source-dirs: prelude
+@@ -255,12 +258,15 @@ Flag executable
+ Description: Build skylighting CLI tool
+ Default: False
+
++Flag system-pcre
++ Description: Use regex-pcre instead of regex-pcre-builtin
++ Default: False
++
+ executable skylighting-extract
+ build-depends: base >= 4.7 && < 5.0,
+ filepath,
+ bytestring,
+ text,
+- regex-pcre-builtin,
+ safe,
+ hxt,
+ utf8-string,
+@@ -269,6 +275,10 @@ executable skylighting-extract
+ pretty-show,
+ containers,
+ directory
++ if flag(system-pcre)
++ build-depends: regex-pcre
++ else
++ build-depends: regex-pcre-builtin
+ hs-source-dirs: bin, src
+ if impl(ghc < 7.10)
+ hs-source-dirs: prelude
More information about the arch-commits
mailing list