-
Notifications
You must be signed in to change notification settings - Fork 234
Object file (lse.o) with __aarch64_have_lse_atomics symbol included several times in static library #443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
The actual source is here: Line 526 in ec8b848
Essentially we compile the same |
Given that libtool has been around for decades, is very widely used, enforces this requirement without issue in all the other software I know… maybe it would be better to avoid this situation altogether. |
I don't know rust, as I stated, but there is clearly a deliberate effort made here to avoid having all of these object files in the same library: Line 550 in ec8b848
It should be possible to similarly name the object files |
I think it uses different static library names due to the cc crate requiring the same configuration for the entire static library. In this case it is necessary to compile the same source file with multiple configuration options, so it needs to use multiple static libraries to let cc do this. |
I think the best fix would be to make rustc rename object files when bundelling static libraries to avoid conflicts. This is the only way to ensure that object file names are always unique inside the produced static library even if multiple crates include a static library from unrelated projects that use the same object file name like for example |
The |
This is needed by libtool which rejects archives that contain object files with the same name multiple times. Fixes rust-lang#443
This is needed by libtool which rejects archives that contain object files with the same name multiple times. Fixes rust-lang#443
This is needed by libtool which rejects archives that contain object files with the same name multiple times. Fixes rust-lang#443
We applied the patch from #444 to our build of Rust (see Homebrew/homebrew-core#90103), but we're still seeing the exact same error:
Did I do this wrong, or...? |
This patch is included in compiler-builtins 0.1.55. Make sure that the Cargo.lock from rust-lang/rust that you are using has at least that version for the compiler-builtins crate. |
I see. What I did was patch the source in |
Are you passing |
We are not. But it seems passing it is also complicated, as we need to update the checksums of the vendored sources. Patching the We probably will be using |
|
Fix building of librsvg 2.52+ on arm64. See: rust-lang/compiler-builtins#443 See: rust-lang/compiler-builtins#444
Fix building of librsvg 2.52+ on arm64. See: rust-lang/compiler-builtins#443 See: rust-lang/compiler-builtins#444
This is needed by libtool which rejects archives that contain object files with the same name multiple times. Fixes rust-lang#443
Hi, I'm a Homebrew maintainer, trying to build librsvg on macOS with the latest rust. The issue encountered is reported at librsvg (https://gitlab.gnome.org/GNOME/librsvg/-/issues/787) but my investigation makes me think it's a compiler-builtins issue.
The issue in short is this: a static library file, created by
cargo
in this way:The
librsvg_c_api.a
file that is produced contains many times the same object file (lse.o
), which I think comes from this project, because of:compiler-builtins/build.rs
Line 510 in ec8b848
This, in turn, leads to build failure at the next step, because a static library is supposed to have object files with unique names (libtool enforces that).
I'm not a Rust user myself, just trying to help debug this issue and move forward so we can ship this new version. So I hope my deductions are valid…
The text was updated successfully, but these errors were encountered: