Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
1516a75
haskellPackages.leveldb-haskell: unbreak
rnhmjoj Jun 5, 2024
9106eb8
haskellPackages.selda: unbreak
rnhmjoj Jun 5, 2024
4636757
haskellPackages.scat: unbreak
rnhmjoj Jun 5, 2024
6457cf0
haskell.compiler.ghc96: hadrian patch fix for fully_static
Jun 4, 2024
3fab5eb
haskellPackages.lens-sop: fix build
alexfmpe May 31, 2024
fb51693
fix Spock-core haskellPackage
sspeaks Jun 1, 2024
c23d3f1
Merge branch master into haskell-updates
sternenseemann Jun 8, 2024
b26f1fe
Merge master into haskell-updates
github-actions[bot] Jun 9, 2024
51bd20f
Merge master into haskell-updates
github-actions[bot] Jun 10, 2024
e160c2a
haskellPackages: build with RTS -A64M options
wolfgangwalther Jun 4, 2024
8a0c494
Merge master into haskell-updates
github-actions[bot] Jun 11, 2024
3f15695
Merge master into haskell-updates
github-actions[bot] Jun 12, 2024
e99a168
Merge pull request #317451 from rnhmjoj/pr-haskell-fixes
maralorn Jun 12, 2024
702d636
haskell.compiler.ghc948: fix expression file name
sternenseemann Jun 11, 2024
8ebd50f
haskell.compiler.*: calculate tool path using common function
sternenseemann Jun 11, 2024
076e365
Merge master into haskell-updates
sternenseemann Jun 12, 2024
ec7ba84
Merge master into haskell-updates
github-actions[bot] Jun 13, 2024
85a9715
Merge master into haskell-updates
github-actions[bot] Jun 14, 2024
504729e
haskellPackages.set-extra: Unmark broken
infinisil Jun 14, 2024
ceebde5
haskellPackages.push-notify-apn: unbroken
mpscholten Jun 14, 2024
cadb3d1
haskellPackages.ghcjs-dom: build on js backend of ghc 9.8
alexfmpe Jun 14, 2024
04a9fe9
Merge master into haskell-updates
github-actions[bot] Jun 15, 2024
7070f7b
Merge pull request #319881 from tweag/set-extra-unmark-broken
tomberek Jun 15, 2024
7b8f253
Merge master into haskell-updates
github-actions[bot] Jun 16, 2024
5243bf6
Merge master into haskell-updates
github-actions[bot] Jun 17, 2024
180957a
Merge pull request #319890 from mpscholten/push-notify-apn-unbroken
maralorn Jun 17, 2024
1d68e8d
haskellPackages.html-parse: unbreak
slotThe Jun 15, 2024
eb15303
Merge pull request #320038 from slotThe/html-parse-unbreak
maralorn Jun 17, 2024
ca1281b
haskellPackages.warp: fix build on darwin
alexfmpe May 30, 2024
5169cbe
haskellPackages.jsaddle-warp: fix on ghc 9.8
alexfmpe May 30, 2024
128d023
haskellPackages.jsaddle-dom: remove override
alexfmpe May 30, 2024
78e2348
haskellPackages.jsaddle-hello: fix on darwin
alexfmpe May 31, 2024
9036501
haskellPackages.ghcjs-dom-hello: fix on darwin
alexfmpe May 31, 2024
e07bc34
Merge master into haskell-updates
github-actions[bot] Jun 18, 2024
7c6a6d1
Merge master into haskell-updates
github-actions[bot] Jun 19, 2024
d8989a7
haskellPackages.ghcjs-base: fix build under old ghcjs
alexfmpe Jun 19, 2024
d98cbf2
haskellPackages.ghcjs-websockets: fix build under old ghcjs
alexfmpe Jun 19, 2024
b552f61
haskellPackages.ghcjs-base: disable support when building outside of …
alexfmpe Jun 19, 2024
e9a349a
haskellPackages.ghcjs-prim: Clarify comment
alexfmpe Jun 19, 2024
f7227f3
haskellPackages.hledger-iadd: Remove broken flag
fmlatghore Jun 17, 2024
96a701f
haskellPackages: add mpscholten as maintainer
mpscholten Jun 17, 2024
17d6c23
Merge pull request #321004 from alexfmpe/ghcjs-wrap-up
maralorn Jun 19, 2024
49f3b03
Merge master into haskell-updates
github-actions[bot] Jun 20, 2024
e66e7c4
Merge branch master into haskell-updates
sternenseemann Jun 20, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 49 additions & 28 deletions pkgs/development/compilers/ghc/8.10.7.nix
Original file line number Diff line number Diff line change
Expand Up @@ -131,23 +131,44 @@ let

targetCC = builtins.head toolsForTarget;

# Sometimes we have to dispatch between the bintools wrapper and the unwrapped
# derivation for certain tools depending on the platform.
bintoolsFor = {
# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then targetCC.bintools
else targetCC.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then targetCC.bintools
else targetCC.bintools.bintools;
};
# toolPath calculates the absolute path to the name tool associated with a
# given `stdenv.cc` derivation, i.e. it picks the correct derivation to take
# the tool from (cc, cc.bintools, cc.bintools.bintools) and adds the correct
# subpath of the tool.
toolPath = name: cc:
let
tools = {
"cc" = cc;
"c++" = cc;
as = cc.bintools.bintools;

ar = cc.bintools.bintools;
ranlib = cc.bintools.bintools;
nm = cc.bintools.bintools;
readelf = cc.bintools.bintools;

ld = cc.bintools;
"ld.gold" = cc.bintools;

otool = cc.bintools.bintools;

# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin. We decide based on target platform to have consistent tools
# across all GHC stages.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then cc.bintools
else cc.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then cc.bintools
else cc.bintools.bintools;
}.${name};
in
"${tools}/bin/${tools.targetPrefix}${name}";

# Use gold either following the default, or to avoid the BFD linker due to some bugs / perf issues.
# But we cannot avoid BFD when using musl libc due to https://sourceware.org/bugzilla/show_bug.cgi?id=23856
Expand Down Expand Up @@ -255,19 +276,19 @@ stdenv.mkDerivation (rec {
done
# GHC is a bit confused on its cross terminology, as these would normally be
# the *host* tools.
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
export CXX="${targetCC}/bin/${targetCC.targetPrefix}c++"
export CC="${toolPath "cc" targetCC}"
export CXX="${toolPath "c++" targetCC}"
# Use gold to work around https://sourceware.org/bugzilla/show_bug.cgi?id=16177
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld${lib.optionalString useLdGold ".gold"}"
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
export STRIP="${bintoolsFor.strip}/bin/${bintoolsFor.strip.targetPrefix}strip"
export LD="${toolPath "ld${lib.optionalString useLdGold ".gold"}" targetCC}"
export AS="${toolPath "as" targetCC}"
export AR="${toolPath "ar" targetCC}"
export NM="${toolPath "nm" targetCC}"
export RANLIB="${toolPath "ranlib" targetCC}"
export READELF="${toolPath "readelf" targetCC}"
export STRIP="${toolPath "strip" targetCC}"
'' + lib.optionalString (stdenv.targetPlatform.linker == "cctools") ''
export OTOOL="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}otool"
export INSTALL_NAME_TOOL="${bintoolsFor.install_name_tool}/bin/${bintoolsFor.install_name_tool.targetPrefix}install_name_tool"
export OTOOL="${toolPath "otool" targetCC}"
export INSTALL_NAME_TOOL="${toolPath "install_name_tool" targetCC}"
'' + lib.optionalString useLLVM ''
export LLC="${lib.getBin buildTargetLlvmPackages.llvm}/bin/llc"
export OPT="${lib.getBin buildTargetLlvmPackages.llvm}/bin/opt"
Expand Down
89 changes: 57 additions & 32 deletions pkgs/development/compilers/ghc/common-hadrian.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
, pkgsBuildTarget
, pkgsHostTarget
, targetPackages
, fetchpatch

# build-tools
, bootPkgs
Expand Down Expand Up @@ -170,6 +171,13 @@
then ./docs-sphinx-7-ghc98.patch
else ./docs-sphinx-7.patch )
]
++ lib.optionals (lib.versionAtLeast version "9.6" && lib.versionOlder version "9.8") [
(fetchpatch {
name = "fix-fully_static.patch";
url = "https://gitlab.haskell.org/ghc/ghc/-/commit/1bb24432ff77e11a0340a7d8586e151e15bba2a1.diff";
hash = "sha256-MpvTmFFsNiPDoOp9BhZyWeapeibQ77zgEV+xzZ1UAXs=";
})
]
++ lib.optionals (stdenv.targetPlatform.isDarwin && stdenv.targetPlatform.isAarch64) [
# Prevent the paths module from emitting symbols that we don't use
# when building with separate outputs.
Expand Down Expand Up @@ -259,23 +267,44 @@ let

targetCC = builtins.head toolsForTarget;

# Sometimes we have to dispatch between the bintools wrapper and the unwrapped
# derivation for certain tools depending on the platform.
bintoolsFor = {
# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then targetCC.bintools
else targetCC.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then targetCC.bintools
else targetCC.bintools.bintools;
};
# toolPath calculates the absolute path to the name tool associated with a
# given `stdenv.cc` derivation, i.e. it picks the correct derivation to take
# the tool from (cc, cc.bintools, cc.bintools.bintools) and adds the correct
# subpath of the tool.
toolPath = name: cc:
let
tools = {
"cc" = cc;
"c++" = cc;
as = cc.bintools.bintools;

ar = cc.bintools.bintools;
ranlib = cc.bintools.bintools;
nm = cc.bintools.bintools;
readelf = cc.bintools.bintools;

ld = cc.bintools;
"ld.gold" = cc.bintools;

otool = cc.bintools.bintools;

# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin. We decide based on target platform to have consistent tools
# across all GHC stages.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then cc.bintools
else cc.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then cc.bintools
else cc.bintools.bintools;
}.${name};
in
"${tools}/bin/${tools.targetPrefix}${name}";

# Use gold either following the default, or to avoid the BFD linker due to some bugs / perf issues.
# But we cannot avoid BFD when using musl libc due to https://sourceware.org/bugzilla/show_bug.cgi?id=23856
Expand Down Expand Up @@ -321,19 +350,19 @@ stdenv.mkDerivation ({
done
# GHC is a bit confused on its cross terminology, as these would normally be
# the *host* tools.
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
export CXX="${targetCC}/bin/${targetCC.targetPrefix}c++"
export CC="${toolPath "cc" targetCC}"
export CXX="${toolPath "c++" targetCC}"
# Use gold to work around https://sourceware.org/bugzilla/show_bug.cgi?id=16177
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld${lib.optionalString useLdGold ".gold"}"
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
export STRIP="${bintoolsFor.strip}/bin/${bintoolsFor.strip.targetPrefix}strip"
export LD="${toolPath "ld${lib.optionalString useLdGold ".gold"}" targetCC}"
export AS="${toolPath "as" targetCC}"
export AR="${toolPath "ar" targetCC}"
export NM="${toolPath "nm" targetCC}"
export RANLIB="${toolPath "ranlib" targetCC}"
export READELF="${toolPath "readelf" targetCC}"
export STRIP="${toolPath "strip" targetCC}"
'' + lib.optionalString (stdenv.targetPlatform.linker == "cctools") ''
export OTOOL="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}otool"
export INSTALL_NAME_TOOL="${bintoolsFor.install_name_tool}/bin/${bintoolsFor.install_name_tool.targetPrefix}install_name_tool"
export OTOOL="${toolPath "otool" targetCC}"
export INSTALL_NAME_TOOL="${toolPath "install_name_tool" targetCC}"
'' + lib.optionalString useLLVM ''
export LLC="${lib.getBin buildTargetLlvmPackages.llvm}/bin/llc"
export OPT="${lib.getBin buildTargetLlvmPackages.llvm}/bin/opt"
Expand Down Expand Up @@ -555,10 +584,6 @@ stdenv.mkDerivation ({
] ++ lib.teams.haskell.members;
timeout = 24 * 3600;
inherit (ghc.meta) license platforms;
# https://github.com/NixOS/nixpkgs/issues/208959
broken =
(lib.versionAtLeast version "9.6" && lib.versionOlder version "9.8")
&& stdenv.targetPlatform.isStatic;
};

dontStrip = targetPlatform.useAndroidPrebuilt || targetPlatform.isWasm;
Expand Down
77 changes: 49 additions & 28 deletions pkgs/development/compilers/ghc/common-make-native-bignum.nix
Original file line number Diff line number Diff line change
Expand Up @@ -136,23 +136,44 @@ let

targetCC = builtins.head toolsForTarget;

# Sometimes we have to dispatch between the bintools wrapper and the unwrapped
# derivation for certain tools depending on the platform.
bintoolsFor = {
# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then targetCC.bintools
else targetCC.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then targetCC.bintools
else targetCC.bintools.bintools;
};
# toolPath calculates the absolute path to the name tool associated with a
# given `stdenv.cc` derivation, i.e. it picks the correct derivation to take
# the tool from (cc, cc.bintools, cc.bintools.bintools) and adds the correct
# subpath of the tool.
toolPath = name: cc:
let
tools = {
"cc" = cc;
"c++" = cc;
as = cc.bintools.bintools;

ar = cc.bintools.bintools;
ranlib = cc.bintools.bintools;
nm = cc.bintools.bintools;
readelf = cc.bintools.bintools;

ld = cc.bintools;
"ld.gold" = cc.bintools;

otool = cc.bintools.bintools;

# GHC needs install_name_tool on all darwin platforms. On aarch64-darwin it is
# part of the bintools wrapper (due to codesigning requirements), but not on
# x86_64-darwin. We decide based on target platform to have consistent tools
# across all GHC stages.
install_name_tool =
if stdenv.targetPlatform.isAarch64
then cc.bintools
else cc.bintools.bintools;
# Same goes for strip.
strip =
# TODO(@sternenseemann): also use wrapper if linker == "bfd" or "gold"
if stdenv.targetPlatform.isAarch64 && stdenv.targetPlatform.isDarwin
then cc.bintools
else cc.bintools.bintools;
}.${name};
in
"${tools}/bin/${tools.targetPrefix}${name}";

# Use gold either following the default, or to avoid the BFD linker due to some bugs / perf issues.
# But we cannot avoid BFD when using musl libc due to https://sourceware.org/bugzilla/show_bug.cgi?id=23856
Expand Down Expand Up @@ -265,19 +286,19 @@ stdenv.mkDerivation (rec {
done
# GHC is a bit confused on its cross terminology, as these would normally be
# the *host* tools.
export CC="${targetCC}/bin/${targetCC.targetPrefix}cc"
export CXX="${targetCC}/bin/${targetCC.targetPrefix}c++"
export CC="${toolPath "cc" targetCC}"
export CXX="${toolPath "c++" targetCC}"
# Use gold to work around https://sourceware.org/bugzilla/show_bug.cgi?id=16177
export LD="${targetCC.bintools}/bin/${targetCC.bintools.targetPrefix}ld${lib.optionalString useLdGold ".gold"}"
export AS="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}as"
export AR="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ar"
export NM="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}nm"
export RANLIB="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}ranlib"
export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf"
export STRIP="${bintoolsFor.strip}/bin/${bintoolsFor.strip.targetPrefix}strip"
export LD="${toolPath "ld${lib.optionalString useLdGold ".gold"}" targetCC}"
export AS="${toolPath "as" targetCC}"
export AR="${toolPath "ar" targetCC}"
export NM="${toolPath "nm" targetCC}"
export RANLIB="${toolPath "ranlib" targetCC}"
export READELF="${toolPath "readelf" targetCC}"
export STRIP="${toolPath "strip" targetCC}"
'' + lib.optionalString (stdenv.targetPlatform.linker == "cctools") ''
export OTOOL="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}otool"
export INSTALL_NAME_TOOL="${bintoolsFor.install_name_tool}/bin/${bintoolsFor.install_name_tool.targetPrefix}install_name_tool"
export OTOOL="${toolPath "otool" targetCC}"
export INSTALL_NAME_TOOL="${toolPath "install_name_tool" targetCC}"
'' + lib.optionalString useLLVM ''
export LLC="${lib.getBin buildTargetLlvmPackages.llvm}/bin/llc"
export OPT="${lib.getBin buildTargetLlvmPackages.llvm}/bin/opt"
Expand Down
Loading