Bug 2177458

Summary: symbol lookup error: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc
Product: [Fedora] Fedora Reporter: publiccontact2020
Component: libwebpAssignee: Sandro Mani <manisandro>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: manisandro, mikel, ngompa13, yaneti
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-03-31 20:35:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description publiccontact2020 2023-03-12 00:46:14 UTC
Description of problem:webp-pixbuf-loader-0.2.2-1.fc39 breaks ffmpeg and fails to render webp file format as tested with eye-of-mate and eye-of-gnome

Version-Release number of selected component (if applicable):
webp-pixbuf-loader-0.2.2-1.fc39

How reproducible:
sudo dnf install webp-pixbuf-loader

Steps to Reproduce:
1.sudo dnf install webp-pixbuf-loader
2.breaks ffmpeg (ffmpeg-6.0-2.fc39)
3.failure to render of webp file format as noted above

Actual results: 

undefined symbol

ffmpeg
ffmpeg: symbol lookup error: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

webp-pixbuf-loader-0.2.2-1.fc39 g_module_open() failed for /usr/lib64/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-webp.so: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

Expected results:
render webp graphics in eom and eog
function without breaking ffmpeg 

Additional info:

Comment 1 Mikel Olasagasti Uranga 2023-03-12 09:52:16 UTC
I'm not sure if the problem is related to webp-pixbuf-loader.

Do you get both errors using ffmpeg or is the first one using ffmpeg and the second one using eog?

> ffmpeg: symbol lookup error: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

This should be unrelated to webp-pixbuf-loader.

I tried to reproduce in rawhide but only ffmpeg-free-5.1.2 is available. Are you using rpmfusion version of ffmpeg?

Would something like `ffmpeg -i test.png -c:v libwebp out.webp` trigger the error?

Comment 2 Neal Gompa 2023-03-12 14:43:54 UTC
I tested this with ffmpeg-free-6.0 that I just built, and it seems fine as well.

I think this is with RPM Fusion's ffmpeg package, so this isn't an issue on our side.

FYI: Fedora has ffmpeg available as ffmpeg-free. :)

Comment 3 publiccontact2020 2023-03-12 17:40:46 UTC
The bug report involved failed installation of webp-pixbuf-loader as undicated above and repeated here:

webp-pixbuf-loader-0.2.2-1.fc39 g_module_open() failed for /usr/lib64/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-webp.so: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

Throws and undefined symbol issue and webp graphic fails to render in both eye-of-mate and eye-of-gnome.

There appears to be a bug exclusive of ffmpeg (fusion), and although there  is an issue with ffmpeg that may not be due
to webp-pixbuf-loader, there still remains a problem with package install and graphic rendering apart from the ffmpeg issue.

Comment 4 Mikel Olasagasti Uranga 2023-03-13 14:23:19 UTC
> webp-pixbuf-loader-0.2.2-1.fc39 g_module_open() failed for /usr/lib64/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-webp.so: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

- This error happens with eog or with ffmpeg?
- Can you provide how do you reproduce the problem with ffmpeg? Is converting a jpg to webp like with `ffmpeg -i test.png -c:v libwebp out.webp` enough?
- Can you provide the output for: rpm -qa --queryformat "%{NAME} %{VERSION} %{RELEASE} %{VENDOR}\n" |egrep "ffmpeg|libwebp|webp-pixbuf-loader|eog"

Comment 5 publiccontact2020 2023-03-13 16:06:16 UTC
There are two separate issues here.  The issue with ffmpeg and undefined symbol occurs when attempting to perform a task unrelated to webp.  I can accept that this may be beyond redhat responsibility due to ffmpeg fusion release.

Separate and distinct is the undefined symbol error and failure to display the graphic when attempting to view a webp graphic in either eye-of-mate or eye-of-gnome.

Due to the failure to install reference (see below), it appears there is a problem with webp-pixbuf-loader:

webp-pixbuf-loader-0.2.2-1.fc39 g_module_open() failed for /usr/lib64/gdk-pixbuf-2.0/2.10.0/loaders/libpixbufloader-webp.so: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

per request- Can you provide the output for: rpm -qa --queryformat "%{NAME} %{VERSION}
%{RELEASE} %{VENDOR}\n" |egrep "ffmpeg|libwebp|webp-pixbuf-loader|eog"

rpm -qa --queryformat "%{NAME} %{VERSION}
%{RELEASE} %{VENDOR}\n" |egrep "ffmpeg|libwebp|webp-pixbuf-loader|eog"
egrep: warning: egrep is obsolescent; using grep -E
compat-ffmpeg4 4.4.3
perl-Geography-Countries 2009041301
eog 44~beta
ffmpeg-libs 6.0
ffmpeg 6.0
compat-libwebp05 0.5.2
libwebp 1.3.0
libwebp-devel 1.3.0
webp-pixbuf-loader 0.2.2

Comment 6 Mikel Olasagasti Uranga 2023-03-13 20:15:09 UTC
My understanding is that something is wrong with your libwebp that affects to ffmpeg and whatever is loading the libwebp library. The error you're seeing with ffmpeg, where no pixbufloader is involved, and with eog is the same, but in the case of eog you see some extra error due to extra library (pixbuf) being used to call libwebp.

For rpm command, please, use it as a oneliner:

rpm -qa --queryformat "%{NAME} %{VERSION} %{RELEASE} %{VENDOR}\n" |egrep "ffmpeg|libwebp|webp-pixbuf-loader|eog"

It should output something like:

libwebp 1.3.0 2.fc38 Fedora Project
webp-pixbuf-loader 0.2.2 1.fc39 Fedora Project
eog 44~beta 1.fc39 Fedora Project
ffmpeg-libs 6.0 2.fc39 RPM Fusion
ffmpeg 6.0 2.fc39 RPM Fusion

Comment 7 publiccontact2020 2023-03-13 23:49:03 UTC
Running as a one liner:

rpm -qa --queryformat "%{NAME} %{VERSION} %{RELEASE} %{VENDOR}\n" |egrep "ffmpeg|libwebp|webp-pixbuf-loader|eog"
egrep: warning: egrep is obsolescent; using grep -E
compat-ffmpeg4 4.4.3 1.fc38 RPM Fusion
perl-Geography-Countries 2009041301 37.fc38 Fedora Project
eog 44~beta 1.fc39 Fedora Project
ffmpeg-libs 6.0 2.fc39 RPM Fusion
ffmpeg 6.0 2.fc39 RPM Fusion
compat-libwebp05 0.5.2 3.fc26 Fedora Project
libwebp 1.3.0 2.fc38 Fedora Project
libwebp-devel 1.3.0 2.fc38 Fedora Project
webp-pixbuf-loader 0.2.2 1.fc39 Fedora Project

Comment 8 Mikel Olasagasti Uranga 2023-03-14 08:25:16 UTC
I'm starting to think your system has something broken and that the issue is not a bug in ffmpeg, libwebp or webp-pixbuf-loader.

- Can you check the hash of /usr/lib64/libwebpmux.so.3 and /lib64/libwebpmux.so.3 ?

# md5sum /usr/lib64/libwebpmux.so.3 /lib64/libwebpmux.so.3
969a04333735ef76843ba404bd45005f  /usr/lib64/libwebpmux.so.3
969a04333735ef76843ba404bd45005f  /lib64/libwebpmux.so.3

- Can you check, after installing binutils, libwebpmux.so.3 library with nm -gD /usr/lib64/libwebpmux.so.3  and with the version in /lib64?

# nm -gD /usr/lib64/libwebpmux.so.3 |grep WebPMalloc
                 U WebPMalloc

# nm -gD /lib64/libwebpmux.so.3 |grep WebPMall
                 U WebPMalloc

> compat-libwebp05 0.5.2 3.fc26 Fedora Project

This package is from 2016, is it requried?

You can check non current packages with `remove-retired-packages`:

# dnf install remove-retired-packages
# remove-retired-packages 26

But doing a `dnf remove compat-libwebp05` might be simpler for this scenario.

Comment 9 publiccontact2020 2023-03-14 16:58:43 UTC
requested info from terminal output:

md5sum /usr/lib64/libwebpmux.so.3 /lib64/libwebpmux.so.3
969a04333735ef76843ba404bd45005f  /usr/lib64/libwebpmux.so.3
969a04333735ef76843ba404bd45005f  /lib64/libwebpmux.so.3

nm -gD /usr/lib64/libwebpmux.so.3 | grep WebPMalloc
                 U WebPMalloc
nm -gD /lib64/libwebpmux.so.3 | grep WebPMalloc
                 U WebPMalloc

compat-libwebp05 removed

erasing ffmpeg fusion and installing ffmpeg-free continues to produce undefined symbol output

# ffmpeg
ffmpeg: symbol lookup error: /lib64/libwebpmux.so.3: undefined symbol: WebPMalloc

eye-of-gnome continues to output unrecognied file format and fails to display webp graphic.

Comment 10 Mikel Olasagasti Uranga 2023-03-14 17:09:36 UTC
Changing the component to libwebp as the problem with ffmpeg is not related to webp-pixbuf-loader.

@libwebp team, I've run out of ideas for the moment. Have you seen any error similar to the one described?

Comment 11 Sandro Mani 2023-03-14 17:23:52 UTC
WebPMalloc is defined in libwebp.so.7

$ readelf -Ws  /usr/lib64/libwebp.so.7 | grep WebPMalloc
    65: 0000000000051470    17 FUNC    GLOBAL DEFAULT   14 WebPMalloc

but undefined in libwebpmux.so.3

$ readelf -Ws  /usr/lib64/libwebpmux.so.3 | grep WebPMalloc
    21: 0000000000000000     0 FUNC    GLOBAL DEFAULT  UND WebPMalloc

However libwebpmux.so.3 has a dependency on libwebp.so.7, so all is good on that front:

$ ldd /usr/lib64/libwebpmux.so.3
        [...]
        libwebp.so.7 => /lib64/libwebp.so.7 (0x00007f4a09112000)
        [...]

Looks like it could be an incorrect dlopen call (resp incorrect RTDL flags?) [1]


[1] https://unix.stackexchange.com/questions/607652/why-the-dynamic-linker-couldnt-resolve-reference-when-a-shared-library-has-a-de

Comment 12 publiccontact2020 2023-03-17 14:18:32 UTC
Reverted to 030423 backup and webp graphic rendered correctly in eye-of-gnome, although undefined symbol issue continued with ffmpeg.

Ran system update 031523 and webp graphics no longer rendered in eye-of-gnome, undefined symbol issue continued with ffmpeg.  

Situation resolved by substituting libwebpmux.so.3.0.10 from Ubuntu 23.04.  Additonally there was the need to add webp config. to gdk-pixbuf-loaders loaders.cache file.

Webp graphics now render in eye-of-gnome and ffmpeg functions as expected. 

This is not a Redhat solution, but it worked. Leavvig the bug report open and it is up to you if you want to close the issue.
 
Might want to compare Redhat's source with Ubuntu source for resolving the undefined symbol issue.

Thank you to devs.

Comment 13 Mikel Olasagasti Uranga 2023-03-31 20:35:26 UTC
As this is the only report with this issue and many users are using the library without problems, I still think the problem was caused with something in your system. Closing the case as you managed to workaround it.