wrapBintoolsWith: fix final stage NetBSD

Fixes "bintools" on NetBSD -- without this only the version in stdenv
would work, not the one from the final stage.

Andi tried to warn me about this[1].  Andi, I'm sorry for doubting you.

[1]: https://github.com/NixOS/nixpkgs/pull/124499#discussion_r641949801
master
Alyssa Ross 2021-06-07 11:25:11 +00:00
parent 41387135dd
commit 1dcba17714
No known key found for this signature in database
GPG Key ID: F9DBED4859B271C0
1 changed files with 3 additions and 1 deletions

View File

@ -14,7 +14,9 @@
if libc == null then
null
else if stdenvNoCC.targetPlatform.isNetBSD then
if libc != targetPackages.netbsdCross.headers then
if !(targetPackages ? netbsdCross) then
netbsd.ld_elf_so
else if libc != targetPackages.netbsdCross.headers then
targetPackages.netbsdCross.ld_elf_so
else
null