[arch-commits] Commit in haskell-gtk2hs-buildtools/repos (6 files)
Felix Yan
felixonmars at archlinux.org
Fri Jun 16 07:16:14 UTC 2017
Date: Friday, June 16, 2017 @ 07:16:14
Author: felixonmars
Revision: 237510
archrelease: copy trunk to community-staging-i686, community-staging-x86_64
Added:
haskell-gtk2hs-buildtools/repos/community-staging-i686/
haskell-gtk2hs-buildtools/repos/community-staging-i686/PKGBUILD
(from rev 237509, haskell-gtk2hs-buildtools/trunk/PKGBUILD)
haskell-gtk2hs-buildtools/repos/community-staging-i686/float128.patch
(from rev 237509, haskell-gtk2hs-buildtools/trunk/float128.patch)
haskell-gtk2hs-buildtools/repos/community-staging-x86_64/
haskell-gtk2hs-buildtools/repos/community-staging-x86_64/PKGBUILD
(from rev 237509, haskell-gtk2hs-buildtools/trunk/PKGBUILD)
haskell-gtk2hs-buildtools/repos/community-staging-x86_64/float128.patch
(from rev 237509, haskell-gtk2hs-buildtools/trunk/float128.patch)
-----------------------------------------+
community-staging-i686/PKGBUILD | 52 +++++++++++
community-staging-i686/float128.patch | 140 ++++++++++++++++++++++++++++++
community-staging-x86_64/PKGBUILD | 52 +++++++++++
community-staging-x86_64/float128.patch | 140 ++++++++++++++++++++++++++++++
4 files changed, 384 insertions(+)
Copied: haskell-gtk2hs-buildtools/repos/community-staging-i686/PKGBUILD (from rev 237509, haskell-gtk2hs-buildtools/trunk/PKGBUILD)
===================================================================
--- community-staging-i686/PKGBUILD (rev 0)
+++ community-staging-i686/PKGBUILD 2017-06-16 07:16:14 UTC (rev 237510)
@@ -0,0 +1,52 @@
+# $Id$
+# Maintainer: Sergej Pupykin <pupykin.s+arch at gmail.com>
+
+pkgname=haskell-gtk2hs-buildtools
+pkgver=0.13.2.2
+pkgrel=7
+pkgdesc="Tools to build the Gtk2Hs suite of User Interface libraries."
+url="https://hackage.haskell.org/package/gtk2hs-buildtools"
+license=('GPL2')
+arch=('i686' 'x86_64')
+depends=('ghc' 'haskell-random' 'haskell-hashtables')
+makedepends=('alex' 'happy')
+provides=('gtk2hs-buildtools')
+conflicts=('gtk2hs-buildtools')
+replaces=('gtk2hs-buildtools')
+source=("https://hackage.haskell.org/packages/archive/gtk2hs-buildtools/$pkgver/gtk2hs-buildtools-$pkgver.tar.gz"
+ float128.patch)
+md5sums=('d39564d3da1c4225e3758ddb50de5eed'
+ '0ef88deea74635cb30498fd468981454')
+
+prepare() {
+ cd gtk2hs-buildtools-$pkgver
+ # https://github.com/gtk2hs/gtk2hs/issues/200
+ patch -p2 -i ../float128.patch
+}
+
+build() {
+ cd "${srcdir}/gtk2hs-buildtools-${pkgver}"
+
+ runhaskell Setup configure -O --enable-executable-dynamic --enable-shared \
+ --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+ --libsubdir=\$compiler/site-local/\$pkgid
+ 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}/gtk2hs-buildtools-${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/gtk2hs-buildtools"
+ runhaskell Setup copy --destdir="${pkgdir}"
+
+ # Remove static libs
+ find "$pkgdir"/usr/lib -name "*.a" -delete
+}
Copied: haskell-gtk2hs-buildtools/repos/community-staging-i686/float128.patch (from rev 237509, haskell-gtk2hs-buildtools/trunk/float128.patch)
===================================================================
--- community-staging-i686/float128.patch (rev 0)
+++ community-staging-i686/float128.patch 2017-06-16 07:16:14 UTC (rev 237510)
@@ -0,0 +1,140 @@
+commit 326f7a25234f00509751affed0b86c7cd2103b90
+Author: Felix Yan <felixonmars at archlinux.org>
+Date: Mon May 22 21:39:12 2017 +0800
+
+ Add support for `__float128` (fixes #200)
+
+ This patch is following the language-c patch at
+ https://github.com/visq/language-c/pull/33
+
+ With this patch glib and others build fine with GCC 7.1.1.
+
+diff --git a/tools/c2hs/c/CAST.hs b/tools/c2hs/c/CAST.hs
+index 842d1345..81e78529 100644
+--- a/tools/c2hs/c/CAST.hs
++++ b/tools/c2hs/c/CAST.hs
+@@ -301,6 +301,7 @@ data CTypeSpec = CVoidType Attrs
+ | CIntType Attrs
+ | CLongType Attrs
+ | CFloatType Attrs
++ | CFloat128Type Attrs
+ | CDoubleType Attrs
+ | CSignedType Attrs
+ | CUnsigType Attrs
+@@ -324,6 +325,7 @@ instance Pos CTypeSpec where
+ posOf (CIntType at) = posOf at
+ posOf (CLongType at) = posOf at
+ posOf (CFloatType at) = posOf at
++ posOf (CFloat128Type at) = posOf at
+ posOf (CDoubleType at) = posOf at
+ posOf (CSignedType at) = posOf at
+ posOf (CUnsigType at) = posOf at
+@@ -342,6 +344,7 @@ instance Eq CTypeSpec where
+ (CIntType at1) == (CIntType at2) = at1 == at2
+ (CLongType at1) == (CLongType at2) = at1 == at2
+ (CFloatType at1) == (CFloatType at2) = at1 == at2
++ (CFloat128Type at1) == (CFloat128Type at2) = at1 == at2
+ (CDoubleType at1) == (CDoubleType at2) = at1 == at2
+ (CSignedType at1) == (CSignedType at2) = at1 == at2
+ (CUnsigType at1) == (CUnsigType at2) = at1 == at2
+@@ -1058,6 +1061,9 @@ instance Binary CTypeSpec where
+ putByte bh 13
+ put_ bh ar
+ put_ bh as
++ put_ bh (CFloat128Type at) = do
++ putByte bh 14
++ put_ bh at
+ get bh = do
+ h <- getByte bh
+ case h of
+@@ -1108,6 +1114,9 @@ instance Binary CTypeSpec where
+ ar <- get bh
+ as <- get bh
+ return (CTypeOfType ar as)
++ 14 -> do
++ at <- get bh
++ return (CFloat128Type at)
+
+ instance Binary CStorageSpec where
+ put_ bh (CAuto aa) = do
+diff --git a/tools/c2hs/c/CLexer.x b/tools/c2hs/c/CLexer.x
+index b6097c37..0099af5c 100644
+--- a/tools/c2hs/c/CLexer.x
++++ b/tools/c2hs/c/CLexer.x
+@@ -111,7 +111,7 @@ $visible = \ -\127
+ @fractpart = @digits
+ @mantpart = @intpart?\. at fractpart|@intpart\.
+ @exppart = [eE][\+\-]?@digits
+- at suffix = [fFlL]
++ at suffix = [fFlLqQwW]
+
+
+ tokens :-
+@@ -259,6 +259,7 @@ idkwtok ('d':'o':'u':'b':'l':'e':[]) = tok CTokDouble
+ idkwtok ('e':'l':'s':'e':[]) = tok CTokElse
+ idkwtok ('e':'n':'u':'m':[]) = tok CTokEnum
+ idkwtok ('e':'x':'t':'e':'r':'n':[]) = tok CTokExtern
++idkwtok ('_':'_':'f':'l':'o':'a':'t':'1':'2':'8':[]) = tok CTokFloat128
+ idkwtok ('f':'l':'o':'a':'t':[]) = tok CTokFloat
+ idkwtok ('f':'o':'r':[]) = tok CTokFor
+ idkwtok ('g':'o':'t':'o':[]) = tok CTokGoto
+diff --git a/tools/c2hs/c/CParser.y b/tools/c2hs/c/CParser.y
+index b457ce95..5ae0333a 100644
+--- a/tools/c2hs/c/CParser.y
++++ b/tools/c2hs/c/CParser.y
+@@ -191,6 +191,7 @@ else { CTokElse _ }
+ enum { CTokEnum _ }
+ extern { CTokExtern _ }
+ float { CTokFloat _ }
++"__float128" { CTokFloat128 _ }
+ for { CTokFor _ }
+ goto { CTokGoto _ }
+ if { CTokIf _ }
+@@ -656,6 +657,7 @@ basic_type_name
+ | int {% withAttrs $1 $ CIntType }
+ | long {% withAttrs $1 $ CLongType }
+ | float {% withAttrs $1 $ CFloatType }
++ | "__float128" {% withAttrs $1 $ CFloat128Type }
+ | double {% withAttrs $1 $ CDoubleType }
+ | signed {% withAttrs $1 $ CSignedType }
+ | unsigned {% withAttrs $1 $ CUnsigType }
+diff --git a/tools/c2hs/c/CPretty.hs b/tools/c2hs/c/CPretty.hs
+index 2d9ce265..d285436a 100644
+--- a/tools/c2hs/c/CPretty.hs
++++ b/tools/c2hs/c/CPretty.hs
+@@ -83,6 +83,7 @@ instance Pretty CTypeSpec where
+ pretty (CIntType _) = text "int"
+ pretty (CLongType _) = text "long"
+ pretty (CFloatType _) = text "float"
++ pretty (CFloat128Type _) = text "__float128"
+ pretty (CDoubleType _) = text "double"
+ pretty (CSignedType _) = text "signed"
+ pretty (CUnsigType _) = text "unsigned"
+diff --git a/tools/c2hs/c/CTokens.hs b/tools/c2hs/c/CTokens.hs
+index 6ee2b040..1195d9fb 100644
+--- a/tools/c2hs/c/CTokens.hs
++++ b/tools/c2hs/c/CTokens.hs
+@@ -102,6 +102,7 @@ data CToken = CTokLParen !Position -- `('
+ | CTokEnum !Position -- `enum'
+ | CTokExtern !Position -- `extern'
+ | CTokFloat !Position -- `float'
++ | CTokFloat128 !Position -- `__float128'
+ | CTokFor !Position -- `for'
+ | CTokGoto !Position -- `goto'
+ | CTokIf !Position -- `if'
+@@ -217,6 +218,7 @@ instance Pos CToken where
+ posOf (CTokEnum pos ) = pos
+ posOf (CTokExtern pos ) = pos
+ posOf (CTokFloat pos ) = pos
++ posOf (CTokFloat128 pos ) = pos
+ posOf (CTokFor pos ) = pos
+ posOf (CTokGoto pos ) = pos
+ posOf (CTokInt pos ) = pos
+@@ -311,6 +313,7 @@ instance Show CToken where
+ showsPrec _ (CTokEnum _ ) = showString "enum"
+ showsPrec _ (CTokExtern _ ) = showString "extern"
+ showsPrec _ (CTokFloat _ ) = showString "float"
++ showsPrec _ (CTokFloat128 _ ) = showString "__float128"
+ showsPrec _ (CTokFor _ ) = showString "for"
+ showsPrec _ (CTokGoto _ ) = showString "goto"
+ showsPrec _ (CTokIf _ ) = showString "if"
Copied: haskell-gtk2hs-buildtools/repos/community-staging-x86_64/PKGBUILD (from rev 237509, haskell-gtk2hs-buildtools/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD (rev 0)
+++ community-staging-x86_64/PKGBUILD 2017-06-16 07:16:14 UTC (rev 237510)
@@ -0,0 +1,52 @@
+# $Id$
+# Maintainer: Sergej Pupykin <pupykin.s+arch at gmail.com>
+
+pkgname=haskell-gtk2hs-buildtools
+pkgver=0.13.2.2
+pkgrel=7
+pkgdesc="Tools to build the Gtk2Hs suite of User Interface libraries."
+url="https://hackage.haskell.org/package/gtk2hs-buildtools"
+license=('GPL2')
+arch=('i686' 'x86_64')
+depends=('ghc' 'haskell-random' 'haskell-hashtables')
+makedepends=('alex' 'happy')
+provides=('gtk2hs-buildtools')
+conflicts=('gtk2hs-buildtools')
+replaces=('gtk2hs-buildtools')
+source=("https://hackage.haskell.org/packages/archive/gtk2hs-buildtools/$pkgver/gtk2hs-buildtools-$pkgver.tar.gz"
+ float128.patch)
+md5sums=('d39564d3da1c4225e3758ddb50de5eed'
+ '0ef88deea74635cb30498fd468981454')
+
+prepare() {
+ cd gtk2hs-buildtools-$pkgver
+ # https://github.com/gtk2hs/gtk2hs/issues/200
+ patch -p2 -i ../float128.patch
+}
+
+build() {
+ cd "${srcdir}/gtk2hs-buildtools-${pkgver}"
+
+ runhaskell Setup configure -O --enable-executable-dynamic --enable-shared \
+ --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+ --libsubdir=\$compiler/site-local/\$pkgid
+ 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}/gtk2hs-buildtools-${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/gtk2hs-buildtools"
+ runhaskell Setup copy --destdir="${pkgdir}"
+
+ # Remove static libs
+ find "$pkgdir"/usr/lib -name "*.a" -delete
+}
Copied: haskell-gtk2hs-buildtools/repos/community-staging-x86_64/float128.patch (from rev 237509, haskell-gtk2hs-buildtools/trunk/float128.patch)
===================================================================
--- community-staging-x86_64/float128.patch (rev 0)
+++ community-staging-x86_64/float128.patch 2017-06-16 07:16:14 UTC (rev 237510)
@@ -0,0 +1,140 @@
+commit 326f7a25234f00509751affed0b86c7cd2103b90
+Author: Felix Yan <felixonmars at archlinux.org>
+Date: Mon May 22 21:39:12 2017 +0800
+
+ Add support for `__float128` (fixes #200)
+
+ This patch is following the language-c patch at
+ https://github.com/visq/language-c/pull/33
+
+ With this patch glib and others build fine with GCC 7.1.1.
+
+diff --git a/tools/c2hs/c/CAST.hs b/tools/c2hs/c/CAST.hs
+index 842d1345..81e78529 100644
+--- a/tools/c2hs/c/CAST.hs
++++ b/tools/c2hs/c/CAST.hs
+@@ -301,6 +301,7 @@ data CTypeSpec = CVoidType Attrs
+ | CIntType Attrs
+ | CLongType Attrs
+ | CFloatType Attrs
++ | CFloat128Type Attrs
+ | CDoubleType Attrs
+ | CSignedType Attrs
+ | CUnsigType Attrs
+@@ -324,6 +325,7 @@ instance Pos CTypeSpec where
+ posOf (CIntType at) = posOf at
+ posOf (CLongType at) = posOf at
+ posOf (CFloatType at) = posOf at
++ posOf (CFloat128Type at) = posOf at
+ posOf (CDoubleType at) = posOf at
+ posOf (CSignedType at) = posOf at
+ posOf (CUnsigType at) = posOf at
+@@ -342,6 +344,7 @@ instance Eq CTypeSpec where
+ (CIntType at1) == (CIntType at2) = at1 == at2
+ (CLongType at1) == (CLongType at2) = at1 == at2
+ (CFloatType at1) == (CFloatType at2) = at1 == at2
++ (CFloat128Type at1) == (CFloat128Type at2) = at1 == at2
+ (CDoubleType at1) == (CDoubleType at2) = at1 == at2
+ (CSignedType at1) == (CSignedType at2) = at1 == at2
+ (CUnsigType at1) == (CUnsigType at2) = at1 == at2
+@@ -1058,6 +1061,9 @@ instance Binary CTypeSpec where
+ putByte bh 13
+ put_ bh ar
+ put_ bh as
++ put_ bh (CFloat128Type at) = do
++ putByte bh 14
++ put_ bh at
+ get bh = do
+ h <- getByte bh
+ case h of
+@@ -1108,6 +1114,9 @@ instance Binary CTypeSpec where
+ ar <- get bh
+ as <- get bh
+ return (CTypeOfType ar as)
++ 14 -> do
++ at <- get bh
++ return (CFloat128Type at)
+
+ instance Binary CStorageSpec where
+ put_ bh (CAuto aa) = do
+diff --git a/tools/c2hs/c/CLexer.x b/tools/c2hs/c/CLexer.x
+index b6097c37..0099af5c 100644
+--- a/tools/c2hs/c/CLexer.x
++++ b/tools/c2hs/c/CLexer.x
+@@ -111,7 +111,7 @@ $visible = \ -\127
+ @fractpart = @digits
+ @mantpart = @intpart?\. at fractpart|@intpart\.
+ @exppart = [eE][\+\-]?@digits
+- at suffix = [fFlL]
++ at suffix = [fFlLqQwW]
+
+
+ tokens :-
+@@ -259,6 +259,7 @@ idkwtok ('d':'o':'u':'b':'l':'e':[]) = tok CTokDouble
+ idkwtok ('e':'l':'s':'e':[]) = tok CTokElse
+ idkwtok ('e':'n':'u':'m':[]) = tok CTokEnum
+ idkwtok ('e':'x':'t':'e':'r':'n':[]) = tok CTokExtern
++idkwtok ('_':'_':'f':'l':'o':'a':'t':'1':'2':'8':[]) = tok CTokFloat128
+ idkwtok ('f':'l':'o':'a':'t':[]) = tok CTokFloat
+ idkwtok ('f':'o':'r':[]) = tok CTokFor
+ idkwtok ('g':'o':'t':'o':[]) = tok CTokGoto
+diff --git a/tools/c2hs/c/CParser.y b/tools/c2hs/c/CParser.y
+index b457ce95..5ae0333a 100644
+--- a/tools/c2hs/c/CParser.y
++++ b/tools/c2hs/c/CParser.y
+@@ -191,6 +191,7 @@ else { CTokElse _ }
+ enum { CTokEnum _ }
+ extern { CTokExtern _ }
+ float { CTokFloat _ }
++"__float128" { CTokFloat128 _ }
+ for { CTokFor _ }
+ goto { CTokGoto _ }
+ if { CTokIf _ }
+@@ -656,6 +657,7 @@ basic_type_name
+ | int {% withAttrs $1 $ CIntType }
+ | long {% withAttrs $1 $ CLongType }
+ | float {% withAttrs $1 $ CFloatType }
++ | "__float128" {% withAttrs $1 $ CFloat128Type }
+ | double {% withAttrs $1 $ CDoubleType }
+ | signed {% withAttrs $1 $ CSignedType }
+ | unsigned {% withAttrs $1 $ CUnsigType }
+diff --git a/tools/c2hs/c/CPretty.hs b/tools/c2hs/c/CPretty.hs
+index 2d9ce265..d285436a 100644
+--- a/tools/c2hs/c/CPretty.hs
++++ b/tools/c2hs/c/CPretty.hs
+@@ -83,6 +83,7 @@ instance Pretty CTypeSpec where
+ pretty (CIntType _) = text "int"
+ pretty (CLongType _) = text "long"
+ pretty (CFloatType _) = text "float"
++ pretty (CFloat128Type _) = text "__float128"
+ pretty (CDoubleType _) = text "double"
+ pretty (CSignedType _) = text "signed"
+ pretty (CUnsigType _) = text "unsigned"
+diff --git a/tools/c2hs/c/CTokens.hs b/tools/c2hs/c/CTokens.hs
+index 6ee2b040..1195d9fb 100644
+--- a/tools/c2hs/c/CTokens.hs
++++ b/tools/c2hs/c/CTokens.hs
+@@ -102,6 +102,7 @@ data CToken = CTokLParen !Position -- `('
+ | CTokEnum !Position -- `enum'
+ | CTokExtern !Position -- `extern'
+ | CTokFloat !Position -- `float'
++ | CTokFloat128 !Position -- `__float128'
+ | CTokFor !Position -- `for'
+ | CTokGoto !Position -- `goto'
+ | CTokIf !Position -- `if'
+@@ -217,6 +218,7 @@ instance Pos CToken where
+ posOf (CTokEnum pos ) = pos
+ posOf (CTokExtern pos ) = pos
+ posOf (CTokFloat pos ) = pos
++ posOf (CTokFloat128 pos ) = pos
+ posOf (CTokFor pos ) = pos
+ posOf (CTokGoto pos ) = pos
+ posOf (CTokInt pos ) = pos
+@@ -311,6 +313,7 @@ instance Show CToken where
+ showsPrec _ (CTokEnum _ ) = showString "enum"
+ showsPrec _ (CTokExtern _ ) = showString "extern"
+ showsPrec _ (CTokFloat _ ) = showString "float"
++ showsPrec _ (CTokFloat128 _ ) = showString "__float128"
+ showsPrec _ (CTokFor _ ) = showString "for"
+ showsPrec _ (CTokGoto _ ) = showString "goto"
+ showsPrec _ (CTokIf _ ) = showString "if"
More information about the arch-commits
mailing list