Skip to content

Commit

Permalink
Update comments about no_dead_strip
Browse files Browse the repository at this point in the history
  • Loading branch information
Berrysoft committed Nov 16, 2024
1 parent 3ef04f0 commit bf18cb9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions crates/objc2/src/macros/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -439,9 +439,10 @@ macro_rules! __statics_sel {
/// info on "life before main".
#[cfg_attr(
not(all(target_os = "macos", target_arch = "x86")),
// Clang uses `no_dead_strip` in the link section for some reason,
// which other tools (notably some LLVM tools) now assume is
// present, so we have to add it as well.
// Clang uses `no_dead_strip` in the link section for some unknown reason,
// but it makes LTO fail to trim the unused symbols.
// https://github.com/madsmtm/objc2/issues/667
// https://github.com/llvm/llvm-project/issues/114111
link_section = "__DATA,__objc_selrefs,literal_pointers",
)]
#[cfg_attr(
Expand Down

0 comments on commit bf18cb9

Please sign in to comment.