Stream: t-compiler

Topic: Libraries linked by default?


Josh Triplett (Feb 10 2020 at 20:25, on Zulip):

It looks like, by default, rustc adds "-Wl,-Bdynamic" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lutil" to the linker command line on Linux. I'm trying to find out where these come from. It looks like some of those might come from link directives in std, or in std's build.rs file. But in particular, I'm not finding where -lutil comes from.

Hanna Kruppe (Feb 10 2020 at 20:45, on Zulip):

Seems to come from libc, cf. https://github.com/rust-lang/libc/pull/246

Josh Triplett (Feb 10 2020 at 20:48, on Zulip):

Ah, sure enough, thank you.

Last update: Feb 25 2020 at 04:25UTC