Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 923919 - dev-libs/libbpf-1.3.0 fails to compile: ld.lld: error: version script assignment of LIBBPF_0.3.0 to symbol btf__new_split failed: symbol not defined
Summary: dev-libs/libbpf-1.3.0 fails to compile: ld.lld: error: version script assignm...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Patrick McLean
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-02-06 11:02 UTC by Agostino Sarubbo
Modified: 2024-04-02 10:53 UTC (History)
3 users (show)

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


Attachments
build.log (build.log,56.90 KB, text/plain)
2024-02-06 11:02 UTC, Agostino Sarubbo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2024-02-06 11:02:29 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-libs/libbpf-1.3.0 fails to compile.
Discovered on: amd64 (internal ref: clang-lld_tinderbox)
System: CLANG-LLD (https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#CLANG-LLD)

Info about the issue:
https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#CF0014
Comment 1 Agostino Sarubbo gentoo-dev 2024-02-06 11:02:31 UTC
Created attachment 884359 [details]
build.log

build log and emerge --info
Comment 2 Vic Kerr (wikky) 2024-03-12 11:55:35 UTC
This issue also affects 1.2.2.

The following commits implement the missing APIs:
https://github.com/libbpf/libbpf/commit/95b4beb50201267a45cc193e86512996e5c7409a
https://github.com/libbpf/libbpf/commit/5b7613e50fd94b447b3cd18ae3de9dacd5d60cb9

I presume they're slated for a future 1.4 release.

I have trivially back-ported them to 1.2.2 and 1.3. Just remove the libbpf.map changes from the patches.
Alternatively, we could just remove the missing symbols from libbpf.map.

The patches don't apply cleanly as the ebuild sets S="${WORKDIR}/${P}/src" but patches apply to src/, again trivial to fix with sed.
Comment 3 Vic Kerr (wikky) 2024-04-02 10:53:12 UTC
libbpf-1.4.0 has been released on 1 April. The release notes mention:

> btf_ext__raw_data() and btf__new_split() APIs are added back, they were "lost" during libbpf v1.0 release process;

https://github.com/libbpf/libbpf/releases/tag/v1.4.0