Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 915205 - net-wireless/bluez-5.72 fails to link with clang-17: ld.lld: error: version script assignment of 'global' to symbol 'error' failed: symbol not defined
Summary: net-wireless/bluez-5.72 fails to link with clang-17: ld.lld: error: version s...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Pacho Ramos
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: LD-is-lld, systemwide-lld 912821
  Show dependency tree
 
Reported: 2023-10-05 11:17 UTC by ppw0
Modified: 2024-12-08 10:02 UTC (History)
6 users (show)

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


Attachments
build log (net-wireless:bluez-5.70:20231005-111133.log,174.44 KB, text/x-log)
2023-10-05 11:17 UTC, ppw0
Details
emerge --info (emerge_info.log,7.38 KB, text/x-log)
2023-10-05 11:17 UTC, ppw0
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ppw0 2023-10-05 11:17:01 UTC
Created attachment 872164 [details]
build log

In a clang-17[default-libcxx] environment, net-wireless/bluez-5.70 will fail to link during emerge with the following error message:
```
ld.lld: error: version script assignment of 'global' to symbol 'error' failed: symbol not defined
ld.lld: error: version script assignment of 'global' to symbol 'debug' failed: symbol not defined
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:6203: src/bluetoothd] Error 1
make: *** [Makefile:4556: all] Error 2
```

This can be avoided by passing "-Wl,--undefined-version" to LDFLAGS.

Attaching logs.
Comment 1 ppw0 2023-10-05 11:17:25 UTC
Created attachment 872165 [details]
emerge --info
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-01-24 11:10:33 UTC
parona, did you ever send this to the ML? (see comments on https://github.com/bluez/bluez/pull/623)
Comment 3 Agostino Sarubbo gentoo-dev 2024-02-02 15:10:15 UTC
clang-lld_tinderbox has reproduced this issue with version 5.72 - Updating summary.
Comment 4 vadorovsky 2024-02-15 13:02:23 UTC
I don't see this patch being sent to the ML. And bluez doesn't accept Github pull requests.

So far I just applied it to my private overlay and I can confirm it works:

https://gitlab.com/vadorovsky/overlay/-/commit/4f3956048938ba1aa84d19f96cfeaa06f0aa3ea9

But it would be awesome to upstream it.
Comment 5 Pacho Ramos gentoo-dev 2024-11-08 15:48:57 UTC
Is this still valid with 5.79?
Comment 6 ppw0 2024-12-08 03:09:27 UTC
(In reply to Pacho Ramos from comment #5)
> Is this still valid with 5.79?

I get no issues building 5.79.
Comment 7 Pacho Ramos gentoo-dev 2024-12-08 10:02:28 UTC
Thanks for the feedback