Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 942057 - dev-util/bugbite-cli-0.0.12[test] fails to compile with rust-1.82.0: intel.rs:65:(.text._ZN4ring4aead3gcm21detect_implementation17h5226706cc3ff9ff7E+0xf): undefined reference to ring_core_0_17_8_OPENSSL_ia32cap_P
Summary: dev-util/bugbite-cli-0.0.12[test] fails to compile with rust-1.82.0: intel.rs...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Agostino Sarubbo
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-24 08:13 UTC by Agostino Sarubbo
Modified: 2024-11-07 01:58 UTC (History)
3 users (show)

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


Attachments
build.log (build.log,844.43 KB, text/plain)
2024-10-24 08:13 UTC, Agostino Sarubbo
Details
build log with 1.81.0 rust bin (file_942057.txt,878.30 KB, text/plain)
2024-11-06 22:54 UTC, Matt Jolly
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2024-10-24 08:13:50 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-util/bugbite-cli-0.0.12 fails to compile.
Discovered on: amd64 (internal ref: lto_tinderbox)
System: LTO-SYSTEM (https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#LTO)

Info about the issue:
https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#CF0014
Comment 1 Agostino Sarubbo gentoo-dev 2024-10-24 08:13:52 UTC
Created attachment 906629 [details]
build.log

build log and emerge --info
Comment 2 Ionen Wolkens gentoo-dev 2024-10-24 08:46:29 UTC
Haven't thoroughly checked so I could've overlooked something, but seems to only fail when tests are enabled and with rust-1.82 (fine for me with rust-bin-1.81.0).

More specifically it's building something in src_test and failing there.
Comment 3 Ionen Wolkens gentoo-dev 2024-10-24 08:47:32 UTC
(In reply to Ionen Wolkens from comment #2)
> rust-1.82
(as arthurzam pointed on IRC, might be related to rust newly using llvm19)
Comment 4 Tim Harder gentoo-dev 2024-10-26 02:47:01 UTC
Since all linking works as expected and tests pass upstream with rust-1.82 this is likely a Gentoo related issue with how the toolchain handles lto possibly coupled with some upstream linking changes that got stabilized in rust-1.82. Probably could also involve upstream CI not using the same compiler/linker for C code when building rust crates.

Someone could try running tests on Gentoo with lto disabled with rust-1.82 to see if that is indeed causing the issue.

It's also possible to make the TLS provider configurable and avoid using ring (which is currently the main cause of the linking errors), but since the upstream library bugbite uses for HTTP support still defaults to it, I'm hesitant to add generally unnecessary build complexity.
Comment 5 Matt Jolly gentoo-dev 2024-11-06 22:51:44 UTC
Hitting this while attempting revbumps for upcoming slotted rust / cargo eclass changes - 1.82.0 from source.

I've restricted the ebuild from selecting the new 1.82.0 slot (so only 1.79.0, 1.81.0 are valid).

I note that my 1.81.0 is -bin but based on the ticket that should be fine.
Comment 6 Matt Jolly gentoo-dev 2024-11-06 22:52:17 UTC
Huh. Nope. Seeing the same thing on 1.81.0-bin. /me shrugs
Comment 7 Matt Jolly gentoo-dev 2024-11-06 22:54:50 UTC
Created attachment 908042 [details]
build log with 1.81.0 rust bin
Comment 8 Tim Harder gentoo-dev 2024-11-07 01:45:37 UTC
As I expected, after testing this locally it works fine and tests pass with rust-1.82 and 14.2.0 on Gentoo so it seems like it's related to what gcc version is being used since rustc uses that for linking by default.
Comment 9 Ionen Wolkens gentoo-dev 2024-11-07 01:58:36 UTC
fwiw I can't reproduce anymore, no idea what changed beside I do have a bit newer gcc than last time (current 14.2.1_p20241026), I wasn't using gcc-15.