Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 955936 - x11-libs/wxGTK: broken Gentoo-only(!) ABI via version script mangling
Summary: x11-libs/wxGTK: broken Gentoo-only(!) ABI via version script mangling
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal blocker
Assignee: Gentoo wxWidgets project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-05-14 00:43 UTC by Sam James
Modified: 2025-05-17 17:14 UTC (History)
5 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-05-14 00:43:17 UTC
Splitting out the proper fix for bug 955902 into this and keeping bug 955902 for the build fix and compatibility with previous Gentoo builds (preserving the status quo, just fixing the build).

See https://bugs.gentoo.org/955902#c8 onwards for details, but in summary, we have a bunch of seds in the ebuild, and they break the version script upstream supplies, resulting in made-up symbol versions that are Gentoo-specific (!!!)

```
       sed -i \
               -e "s:\(WX_VERSION=\).*:\1${WXVERSION}:" \
               -e "s:\(WX_RELEASE=\).*:\1${WXRELEASE}:" \
               -e "s:\(WX_SUBVERSION=\).*:\1${WXSUBVERSION}:" \
               -e '/WX_VERSION_TAG=/ s:${WX_RELEASE}:3.0:' \ # <--- here
               configure || die
```

I question how much of the seds are necessary at all, but the mangling of the version script is a critical ABI issue as it makes us incompatible with other distributions and upstream binaries.
Comment 1 Larry the Git Cow gentoo-dev 2025-05-14 00:46:50 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8baaa10af7d9944c5bf0fdfc0190cea6abbd296a

commit 8baaa10af7d9944c5bf0fdfc0190cea6abbd296a
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2025-05-14 00:46:00 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2025-05-14 00:46:00 +0000

    x11-libs/wxGTK: bodge ABI issues one more time
    
    See https://bugs.gentoo.org/955902#c8 onwards for details, but in summary,
    we have a bunch of seds in the ebuild, and they break the version script upstream
    supplies, resulting in made-up symbol versions that are Gentoo-specific (!!!)
    
    ```
           sed -i \
                   -e "s:\(WX_VERSION=\).*:\1${WXVERSION}:" \
                   -e "s:\(WX_RELEASE=\).*:\1${WXRELEASE}:" \
                   -e "s:\(WX_SUBVERSION=\).*:\1${WXSUBVERSION}:" \
                   -e '/WX_VERSION_TAG=/ s:${WX_RELEASE}:3.0:' \ # <--- here
                   configure || die
    ```
    
    I question how much of the seds are necessary at all, but the mangling of the version
    script is a critical ABI issue as it makes us incompatible with other distributions
    and upstream binaries.
    
    However, fixing this correctly while also quickly to solve bug #955902
    isn't really feasible, so..
    
    Quickly bodge this by patching the affected symbols in
    https://github.com/wxWidgets/wxWidgets/commit/f3eb19ce2efa839c0d3e8dc922445cbb49bd9e5d
    to have 3.0.x. In for a penny, in for a pound.
    
    Then can try actually fix this once wxGTK is building again and figure out
    proper ABI compatibility with our made up symbols as well as the upstream ones
    in a followup revision. Filed bug #955936 for that proper fix.
    
    TL;DR: Leave proper fixing for it until later to fix the immediate emergency,
    extend the previous hack to newly-added symbols.
    
    Bug: https://bugs.gentoo.org/955936
    Closes: https://bugs.gentoo.org/955902
    Signed-off-by: Sam James <sam@gentoo.org>

 .../files/wxGTK-3.2.8-bodge-version-script.patch   | 94 ++++++++++++++++++++++
 x11-libs/wxGTK/wxGTK-3.2.8.ebuild                  | 22 ++---
 2 files changed, 107 insertions(+), 9 deletions(-)
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-05-14 00:47:51 UTC
Workaround added which does NOT fix the ABI compatibility issue with other distros or upstream.