Bug 461487 - Kate crashes because katefilebrowserplugin.so loads the wrong kio-file-widgets shared library
Summary: Kate crashes because katefilebrowserplugin.so loads the wrong kio-file-widget...
Status: RESOLVED WORKSFORME
Alias: None
Product: frameworks-kcoreaddons
Classification: Frameworks and Libraries
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Michael Pyne
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-06 06:48 UTC by kogiokkafrms
Modified: 2025-01-07 03:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
QT_PLUGIN_PATH=~/kde/usr/lib64/plugins:$QT_PLUGIN_PATH ltrace -C -o ltrace.log ~/kde/usr/bin/kate (33.55 KB, text/x-log)
2022-11-06 06:48 UTC, kogiokkafrms
Details

Note You need to log in before you can comment on or make changes to this bug.
Description kogiokkafrms 2022-11-06 06:48:14 UTC
Created attachment 153513 [details]
QT_PLUGIN_PATH=~/kde/usr/lib64/plugins:$QT_PLUGIN_PATH ltrace -C -o ltrace.log ~/kde/usr/bin/kate

SUMMARY

Kate launched by kdesrc-run crashes because katefilebrowserplugin.so tries to load the wrong version of libKF5KIOFileWidgets.so.5 in the system path (/usr/lib64). The plugin reports a symbol lookup error on "_ZNK12KDirOperator6actionENS_6ActionE".

STEPS TO REPRODUCE
1. Use kdesrc-build to build Kate and install it at ~/kde/usr/ 
2. Execute "kdesrc-run kate"

OBSERVED RESULT
A symbol lookup error message will show, saying that katefilebrowserplugin.so tries to find the undefined symbol "_ZNK12KDirOperator6actionENS_6ActionE". The issue relates to commit 4cfb4123efc89b425dea176ccb5b58ce2f0ad5da.

The issue can be solved by defining LD_LIBRARY_PATH. kdesrc-run uses prefix.sh from build trees to define environment variables. However, the LD_LIBRARY_PATH variable has been commented out with a comment stating that "LD_LIBRARY_PATH only needed if you are building without rpath." I checked the katefilebrowserplugin.so with "readelf -d", and the RUNPATH is pointing to the correct location.

EXPECTED RESULT

The plugin should find the proper KIO library even when the LD_LIBRARY_PATH is not set. Alternatively, LD_LIBRARY_PATH should be set in prefix.sh by default.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Fedora Linux 36
KDE Plasma Version: 5.25.5
KDE Frameworks Version: 5.99.0
Qt Version: 5.15.6

ADDITIONAL INFORMATION
Comment 1 Christoph Cullmann 2022-11-09 20:05:23 UTC
True, something is strange there.

We create the plugins via

kcoreaddons_add_plugin(${name} INSTALL_NAMESPACE "ktexteditor")
Comment 2 Christoph Cullmann 2024-12-08 20:11:20 UTC
This looks like a local issue. Please try to test that again with a fresh master compile.
Comment 3 Bug Janitor Service 2024-12-23 03:47:07 UTC
๐Ÿ›๐Ÿงน โš ๏ธ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!
Comment 4 Bug Janitor Service 2025-01-07 03:47:57 UTC
๐Ÿ›๐Ÿงน This bug has been in NEEDSINFO status with no change for at least 30 days. Closing as RESOLVED WORKSFORME.