Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 915154 - x11-libs/wxGTK-3.2.2.1-r2 fails to link with clang-17: ld.lld: error: version script assignment of 'WXU_3.0.2' to symbol 'wxUILocale::GetSystemLocaleId' failed: symbol not defined
Summary: x11-libs/wxGTK-3.2.2.1-r2 fails to link with clang-17: ld.lld: error: version...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo wxWidgets project
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks: LD-is-lld, systemwide-lld 912821
  Show dependency tree
 
Reported: 2023-10-04 00:07 UTC by ppw0
Modified: 2024-01-21 08:57 UTC (History)
0 users

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


Attachments
build log (x11-libs:wxGTK-3.2.2.1-r2:20231003-230536.log.gz,25.88 KB, application/gzip)
2023-10-04 00:07 UTC, ppw0
Details
emerge --info (emerge_info.log,7.38 KB, text/x-log)
2023-10-04 00:08 UTC, ppw0
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ppw0 2023-10-04 00:07:51 UTC
Created attachment 872115 [details]
build log

In a clang-17[default-libcxx] environment, x11-libs/wxGTK-3.2.2.1-r2 will fail to link during emerge with the following error message:
```
llvm-ranlib /var/tmp/portage/x11-libs/wxGTK-3.2.2.1-r2/work/wxWidgets-3.2.2.1-abi_x86_64.amd64/lib/libwxscintilla-3.2-gtk3.a
ld.lld: error: version script assignment of 'WXU_3.0.2' to symbol 'wxUILocale::GetSystemLocaleId' failed: symbol not defined
ld.lld: error: version script assignment of 'WXU_3.0.2' to symbol 'wxWithImages::GetImageLogicalSize' failed: symbol not defined
ld.lld: error: version script assignment of 'WXU_3.0.2' to symbol 'wxWithImages::GetImageBitmapFor' failed: symbol not defined
ld.lld: error: version script assignment of 'WXU_3.0.1' to symbol 'wxApp::GTKAllowDiagnosticsControl()' failed: symbol not defined
ld.lld: error: version script assignment of 'WXU_3.0.1' to symbol 'wxFileDialog::AddShortcut(const wxString&, int)' failed: symbol not defined
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Makefile:14297: /var/tmp/portage/x11-libs/wxGTK-3.2.2.1-r2/work/wxWidgets-3.2.2.1-abi_x86_64.amd64/lib/libwx_baseu-3.2-gtk3.so.0.2.1] Error 1
make: *** Waiting for unfinished jobs....
```

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

Attaching logs.
Comment 1 ppw0 2023-10-04 00:08:25 UTC
Created attachment 872116 [details]
emerge --info
Comment 2 Larry the Git Cow gentoo-dev 2024-01-21 08:57:15 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4f339194e5c424a7403f70d577a20652c7b5cf6b

commit 4f339194e5c424a7403f70d577a20652c7b5cf6b
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-01-20 20:00:04 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-01-21 08:56:03 +0000

    x11-libs/wxGTK: fix ld.lld errors: version script assignment failed: symbol not defined
    
    ld.lld 17 fix, similar to https://github.com/gentoo/gentoo/pull/34595
    
    Closes: https://bugs.gentoo.org/915154
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Closes: https://github.com/gentoo/gentoo/pull/34926
    Signed-off-by: Sam James <sam@gentoo.org>

 x11-libs/wxGTK/wxGTK-3.0.4-r5.ebuild   | 7 +++++--
 x11-libs/wxGTK/wxGTK-3.0.5.1-r1.ebuild | 7 +++++--
 x11-libs/wxGTK/wxGTK-3.2.1.ebuild      | 7 +++++--
 x11-libs/wxGTK/wxGTK-3.2.2.1-r1.ebuild | 7 +++++--
 x11-libs/wxGTK/wxGTK-3.2.2.1-r2.ebuild | 7 +++++--
 x11-libs/wxGTK/wxGTK-3.2.2.1-r3.ebuild | 5 ++++-
 6 files changed, 29 insertions(+), 11 deletions(-)