Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 925194 - dev-lang/rust-bin: should also set RUSTDOCFLAGS="-C target-features=-crt-static" for musl
Summary: dev-lang/rust-bin: should also set RUSTDOCFLAGS="-C target-features=-crt-stat...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Randy Barlow
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-02-21 18:01 UTC by Violet Purcell
Modified: 2024-02-27 23:26 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Violet Purcell 2024-02-21 18:01:22 UTC
Currently, dev-lang/rust-bin has this line to disable crt-static for musl targets with an env.d file:

$(usev elibc_musl "CARGO_TARGET_${CARGO_TRIPLET}_RUSTFLAGS=\"-C target-feature=-crt-static\"")

However, this doesn't extend to rustdoc commands, so they have the potential to fail due to missing static libs on musl (see https://bugs.gentoo.org/925086).

This would be fixed by adding this line:

$(usev elibc_musl "CARGO_TARGET_${CARGO_TRIPLET}_RUSTDOCFLAGS=\"-C target-feature=-crt-static\"")

Or, would it be better to just handle this in cargo.eclass?