-
-
Notifications
You must be signed in to change notification settings - Fork 13.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bintools-wrapper: skip dynamic linker for static binaries #107596
Conversation
@@ -63,6 +69,11 @@ extraBefore=(${hardeningLDFlags[@]+"${hardeningLDFlags[@]}"}) | |||
if [ -z "${NIX_LDFLAGS_SET_@suffixSalt@:-}" ]; then | |||
extraAfter+=($NIX_LDFLAGS_@suffixSalt@) | |||
extraBefore+=($NIX_LDFLAGS_BEFORE_@suffixSalt@) | |||
# By adding dynamic linker to extraBefore we allow the users set their | |||
# own dynamic linker as NIX_LD_FLAGS will override earlier set flags | |||
if [[ "$setDynamicLinker" = 1 && -n "$NIX_DYNAMIC_LINKER_@suffixSalt@" ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This now checks if a linker is present for the selected cc-wrapper. This was not the case before and broke darwin.
@dasJ could you build |
|
👍🏼 |
f348af4
to
6f452b2
Compare
I think this is unrelated to this PR. |
@SuperSandro2000 what did you try to build? Can you disable the sandbox just for: $ nix-build -A tests.cc-wrapper -A tests.cc-wrapper-clang |
@Mic92 since others seem to do the build stuff, I'll unsubscribe here. Feel free to ping me if you need me again |
Works without sandbox 👍🏼 |
6f452b2
to
61bbbcd
Compare
Package began failing after NixOS#107596 The `nix-support/libc-ldflags-before` file is no longer guaranteed to exist, so this commit ensures the build continues without it.
Motivation for this change
Revised version of #106908
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)