-
-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Rust build support doesn't use NIX_LDFLAGS in link flags #326944
Copy link
Copy link
Closed
Labels
0.kind: bugSomething is brokenSomething is broken1.severity: significantNovel ideas, large API changes, notable refactorings, issues with RFC potential, etc.Novel ideas, large API changes, notable refactorings, issues with RFC potential, etc.6.topic: rustGeneral-purpose programming language emphasizing performance, type safety, and concurrency.General-purpose programming language emphasizing performance, type safety, and concurrency.
Metadata
Metadata
Assignees
Labels
0.kind: bugSomething is brokenSomething is broken1.severity: significantNovel ideas, large API changes, notable refactorings, issues with RFC potential, etc.Novel ideas, large API changes, notable refactorings, issues with RFC potential, etc.6.topic: rustGeneral-purpose programming language emphasizing performance, type safety, and concurrency.General-purpose programming language emphasizing performance, type safety, and concurrency.
Fields
Give feedbackNo fields configured for issues without a type.
Describe the bug
I was trying to use
NIX_LDFLAGSinstead ofLD_LIBRARY_PATHin ukmm to link extra runtime libraries, but ukmm would silently fail to start: #325139 (comment). I noticed that a bunch of other packages were definingRUSTFLAGSto handle this, so I just ended up using that instead, but it was surprising to see thatNIX_LDFLAGSwouldn't work.Steps To Reproduce
Steps to reproduce the behavior:
NIX_LDFLAGSsetNIX_LDFLAGSdon't actually get linked in resulting binariesExpected behavior
NIX_LDFLAGSshould link extra libraries in rust like it does with packages built with c.Notify maintainers
@zowoq @winterqt @figsoda
Metadata
Please run
nix-shell -p nix-info --run "nix-info -m"and paste the result.