From 628ac8b0871553eb9a693ae163f6656739a7fbe2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Fri, 30 May 2014 23:10:19 +0200 Subject: [PATCH] older GHCs: fix build after gcc-4.8.3 bump Getting "frame pointer required, but reserved" while compiling runtime. Thanks to @jwiegley for suggestion of the work-around. --- pkgs/development/compilers/ghc/6.10.4.nix | 2 ++ pkgs/development/compilers/ghc/6.12.3.nix | 2 ++ pkgs/development/compilers/ghc/7.0.4.nix | 2 ++ pkgs/development/compilers/ghc/7.2.2.nix | 2 ++ 4 files changed, 8 insertions(+) diff --git a/pkgs/development/compilers/ghc/6.10.4.nix b/pkgs/development/compilers/ghc/6.10.4.nix index 92afc0f4b88..5d02088c44c 100644 --- a/pkgs/development/compilers/ghc/6.10.4.nix +++ b/pkgs/development/compilers/ghc/6.10.4.nix @@ -20,6 +20,8 @@ stdenv.mkDerivation rec { "--with-gcc=${stdenv.gcc}/bin/gcc" ]; + NIX_CFLAGS_COMPILE = "-fomit-frame-pointer"; + meta = { inherit homepage; description = "The Glasgow Haskell Compiler"; diff --git a/pkgs/development/compilers/ghc/6.12.3.nix b/pkgs/development/compilers/ghc/6.12.3.nix index 05ceba030b9..08c9c1739ed 100644 --- a/pkgs/development/compilers/ghc/6.12.3.nix +++ b/pkgs/development/compilers/ghc/6.12.3.nix @@ -25,6 +25,8 @@ stdenv.mkDerivation rec { "--with-gcc=${stdenv.gcc}/bin/gcc" ]; + NIX_CFLAGS_COMPILE = "-fomit-frame-pointer"; + # required, because otherwise all symbols from HSffi.o are stripped, and # that in turn causes GHCi to abort stripDebugFlags=["-S" "--keep-file-symbols"]; diff --git a/pkgs/development/compilers/ghc/7.0.4.nix b/pkgs/development/compilers/ghc/7.0.4.nix index 1cafdd51bee..ab69df12aa8 100644 --- a/pkgs/development/compilers/ghc/7.0.4.nix +++ b/pkgs/development/compilers/ghc/7.0.4.nix @@ -25,6 +25,8 @@ stdenv.mkDerivation rec { "--with-gcc=${stdenv.gcc}/bin/gcc" ]; + NIX_CFLAGS_COMPILE = "-fomit-frame-pointer"; + # required, because otherwise all symbols from HSffi.o are stripped, and # that in turn causes GHCi to abort stripDebugFlags=["-S" "--keep-file-symbols"]; diff --git a/pkgs/development/compilers/ghc/7.2.2.nix b/pkgs/development/compilers/ghc/7.2.2.nix index c6ec0cb75c4..7e714ae3b78 100644 --- a/pkgs/development/compilers/ghc/7.2.2.nix +++ b/pkgs/development/compilers/ghc/7.2.2.nix @@ -25,6 +25,8 @@ stdenv.mkDerivation rec { "--with-gcc=${stdenv.gcc}/bin/gcc" ]; + NIX_CFLAGS_COMPILE = "-fomit-frame-pointer"; + # required, because otherwise all symbols from HSffi.o are stripped, and # that in turn causes GHCi to abort stripDebugFlags=["-S" "--keep-file-symbols"];