git.iko.soy/typeable/nixpkgs
on master help sign in
binutils: apply patch when cross compiling from darwin

Fixes #60546

commit457b48cc0360380ecd906afdeb314fec93b89168 authorMatthew Bauer <mjbauer95@gmail.com> dateTue 30 Apr 2019, 20:24 (8 years ago) parent5f4a4e9
1 file changed+9−1
pkgs/development/tools/misc/binutils/default.nix+9−1
pkgs/development/tools/misc/binutils/default.nix+9−1
@@ -4,6 +4,7 @@
44, withAllTargets ? false, libbfd, libopcodes
55, enableShared ? true
66, noSysDirs, gold ? true, bison ? null
7+, fetchpatch
78}:
89
910let
@@ -60,7 +61,14 @@ stdenv.mkDerivation rec {
6061 ./0001-x86-Add-a-GNU_PROPERTY_X86_ISA_1_USED-note-if-needed.patch
6162 ./0001-x86-Properly-merge-GNU_PROPERTY_X86_ISA_1_USED.patch
6263 ./0001-x86-Properly-add-X86_ISA_1_NEEDED-property.patch
63− ] ++ lib.optional stdenv.targetPlatform.isiOS ./support-ios.patch;
64+ ] ++ lib.optional stdenv.targetPlatform.isiOS ./support-ios.patch
65+ ++ lib.optional (stdenv.hostPlatform.isDarwin && stdenv.targetPlatform != stdenv.hostPlatform) [
66+ (fetchpatch {
67+ url = "https://sourceware.org/bugzilla/attachment.cgi?id=11141";
68+ name = "gold-threads.patch";
69+ sha256 = "0p26dxpba8n7z3pwjg7qf94f0gzbvwkjq0j9ng1w3sljj0gyaf1j";
70+ })
71+ ];
6472
6573 outputs = [ "out" "info" "man" ];
6674