1
Fork 0
rust/compiler/rustc_codegen_ssa/src
bors 1086affd98 Auto merge of #126094 - petrochenkov:libsearch, r=michaelwoerister
linker: Link dylib crates by path

Linkers seem to support linking dynamic libraries by path.
Not sure why the previous scheme with splitting the path into a directory (passed with `-L`) and a name (passed with `-l`) was used (upd: likely due to https://github.com/rust-lang/rust/pull/126094#issuecomment-2155063414).

When we split a library path `some/dir/libfoo.so` into `-L some/dir` and `-l foo` we add `some/dir` to search directories for *all* libraries looked up by the linker, not just `foo`, and `foo` is also looked up in *all* search directories not just `some/dir`.
Technically we may find some unintended libraries this way.
Therefore linking dylibs via a full path is both simpler and more reliable.

It also makes the set of search directories more easily reproducible when we need to lookup some native library manually (like in https://github.com/rust-lang/rust/pull/123436).
2024-07-03 14:15:31 +00:00
..
back linker: Link dylib crates by path 2024-07-02 11:43:17 +03:00
debuginfo Add Ty to ConstKind::Value 2024-06-05 22:25:41 +01:00
mir Auto merge of #125507 - compiler-errors:type-length-limit, r=lcnr 2024-07-03 11:56:36 +00:00
traits Fix doc comment 2024-06-21 19:30:26 +00:00
assert_module_sources.rs Remove #[macro_use] extern crate tracing from rustc_codegen_ssa. 2024-05-23 18:02:40 +10:00
base.rs Fix spans 2024-07-02 15:48:48 -04:00
codegen_attrs.rs Rollup merge of #124741 - nebulark:patchable-function-entries-pr, r=estebank,workingjubilee 2024-06-28 08:34:07 +02:00
common.rs ScalarInt: size mismatches are a bug, do not delay the panic 2024-06-10 13:43:16 +02:00
errors.rs coverage: Tighten validation of #[coverage(off)] and #[coverage(on)] 2024-06-24 20:15:01 +10:00
lib.rs Use tidy to sort crate attributes for all compiler crates. 2024-06-12 15:49:10 +10:00
meth.rs Move vcall_visibility_metadata optimization hint out of a debuginfo generation method 2024-06-21 19:26:06 +00:00
mono_item.rs Remove #[macro_use] extern crate tracing from rustc_codegen_ssa. 2024-05-23 18:02:40 +10:00
size_of_val.rs Remove #[macro_use] extern crate tracing from rustc_codegen_ssa. 2024-05-23 18:02:40 +10:00
target_features.rs Remove extern crate rustc_middle from numerous crates. 2024-04-29 14:50:45 +10:00