summaryrefslogtreecommitdiff
path: root/p/ghc
diff options
context:
space:
mode:
authorClint Adams <clint@debian.org>2016-11-02 15:52:04 -0400
committerClint Adams <clint@debian.org>2016-11-02 15:52:04 -0400
commit844ec54c6d781a65c8bd75ac36957fd362fc1141 (patch)
tree7f73be8a2f4e9d8b1f1886f353100efe1aef036b /p/ghc
parent9d9b7f85f3d4144c34ec175d52b49e016a71e5a8 (diff)
downloadDHG_packages-844ec54c6d781a65c8bd75ac36957fd362fc1141.tar.gz
ghc/Cabal: Upstream patch c30b179a73d9fd3f6edcdda5e881523cd6edd46a to Cabal, fixing incorrect retrieval of ld flags.
Diffstat (limited to 'p/ghc')
-rw-r--r--p/ghc/debian/changelog5
-rw-r--r--p/ghc/debian/patches/get-linker-flags-correctly43
-rw-r--r--p/ghc/debian/patches/series1
3 files changed, 49 insertions, 0 deletions
diff --git a/p/ghc/debian/changelog b/p/ghc/debian/changelog
index 2bc0db0a2..9660a360b 100644
--- a/p/ghc/debian/changelog
+++ b/p/ghc/debian/changelog
@@ -1,7 +1,12 @@
ghc (8.0.1-10) UNRELEASED; urgency=medium
+ [ Emilio Pozuelo Monfort ]
* Re-enable parallel builds, broken since 7.10.1.20150630-1.
+ [ Clint Adams ]
+ * Upstream patch c30b179a73d9fd3f6edcdda5e881523cd6edd46a to Cabal,
+ fixing incorrect retrieval of ld flags.
+
-- Emilio Pozuelo Monfort <pochu@debian.org> Wed, 02 Nov 2016 10:36:08 +0100
ghc (8.0.1-9) unstable; urgency=medium
diff --git a/p/ghc/debian/patches/get-linker-flags-correctly b/p/ghc/debian/patches/get-linker-flags-correctly
new file mode 100644
index 000000000..4c33bd96c
--- /dev/null
+++ b/p/ghc/debian/patches/get-linker-flags-correctly
@@ -0,0 +1,43 @@
+From c30b179a73d9fd3f6edcdda5e881523cd6edd46a Mon Sep 17 00:00:00 2001
+From: Anders Kaseorg <andersk@mit.edu>
+Date: Thu, 19 May 2016 03:18:02 -0400
+Subject: [PATCH] =?utf8?q?Get=20linker=20flags=20correctly=20from=20GHC=20?=
+ =?utf8?q?=E2=89=A5=207.8?=
+MIME-Version: 1.0
+Content-Type: text/plain; charset=utf8
+Content-Transfer-Encoding: 8bit
+
+GHC 7.8 renamed "Gcc Linker flags" to "C compiler link flags" and "Ld
+Linker flags" to "ld flags"
+(https://ghc.haskell.org/trac/ghc/ticket/4862).
+
+Without this corresponding fix in Cabal, the old-time package fails to
+compile on Ubuntu yakkety amd64, where the system GCC now defaults to
+-pie and GHC has
+
+ $ ghc --info | grep -i pie
+ ,("C compiler flags","-fno-PIE -fno-stack-protector")
+ ,("C compiler link flags","-no-pie")
+ ,("ld flags","-no-pie")
+
+Signed-off-by: Anders Kaseorg <andersk@mit.edu>
+(cherry picked from commit c993a0c6660aa10d8c79ed0cc4961c59acfc91c8)
+---
+ libraries/Cabal/Cabal/Distribution/Simple/GHC/Internal.hs | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+--- a/libraries/Cabal/Cabal/Distribution/Simple/GHC/Internal.hs
++++ b/libraries/Cabal/Cabal/Distribution/Simple/GHC/Internal.hs
+@@ -139,8 +139,10 @@
+ mbStripLocation = M.lookup "strip command" ghcInfo
+
+ ccFlags = getFlags "C compiler flags"
+- gccLinkerFlags = getFlags "Gcc Linker flags"
+- ldLinkerFlags = getFlags "Ld Linker flags"
++ -- GHC 7.8 renamed "Gcc Linker flags" to "C compiler link flags"
++ -- and "Ld Linker flags" to "ld flags" (GHC #4862).
++ gccLinkerFlags = getFlags "Gcc Linker flags" ++ getFlags "C compiler link flags"
++ ldLinkerFlags = getFlags "Ld Linker flags" ++ getFlags "ld flags"
+
+ -- It appears that GHC 7.6 and earlier encode the tokenized flags as a
+ -- [String] in these settings whereas later versions just encode the flags as
diff --git a/p/ghc/debian/patches/series b/p/ghc/debian/patches/series
index 6dc44534c..d7dedf73a 100644
--- a/p/ghc/debian/patches/series
+++ b/p/ghc/debian/patches/series
@@ -10,3 +10,4 @@ opt-pic
no-pie
find-tycon-panic
compiler-cmm-PprC-sparc-alignment.patch
+get-linker-flags-correctly