Bug 400981 - Appimage not working anymore: /lib64/libfontconfig.so.1: undefined symbol: FT_Done_MM_Var
Summary: Appimage not working anymore: /lib64/libfontconfig.so.1: undefined symbol: FT...
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Bundle-AppImage (other bugs)
Version First Reported In: 6.0.0
Platform: Appimage Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-11-12 20:43 UTC by PhilV
Modified: 2019-03-30 18:02 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In: 6.1.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description PhilV 2018-11-12 20:43:16 UTC
SUMMARY
Happens with update of Fedora 28 -> 29: appimage does not work anymore.
Error is related to "/lib64/libfontconfig.so.1: undefined symbol: FT_Done_MM_Var":

./digikam-6.0.0-beta2-x86-64.appimage 
-- digiKam AppImage Bundle
-- Use 'help' as CLI argument to know all available options for digiKam application
ERROR: ld.so: object '/usr/lib64/libfreetype.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libudev.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libfreetype.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libudev.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
digikam: symbol lookup error: /lib64/libfontconfig.so.1: undefined symbol: FT_Done_MM_Var


Was working fine with F28.


ADDITIONAL INFORMATION
fontconfig-2.13.1-3.fc29
freetype-2.9.1-6.fc29

Working workaround, using LD_PRELOAD:
LD_PRELOAD=/lib64/libfreetype.so.6 ./digikam-6.0.0-beta2-x86-64.appimage 

(note however that some warnings 'ignore' are still present:
ERROR: ld.so: object '/usr/lib64/libfreetype.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libudev.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libfreetype.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/usr/lib64/libudev.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
)

Looking on the net, I found a solution for developer: see https://github.com/AppImage/AppImageKit/issues/836
Comment 1 caulier.gilles 2018-11-17 17:34:42 UTC
Look in script used to load AppImage bundle internally :

https://cgit.kde.org/digikam.git/tree/project/bundles/appimage/data/AppRun#n11

The preload rules already exists but they use file in /usr/lib64, not /lib64. /usr/lib64 is the standard place defined in Linux Standard Base for this kind of libraries.

Gilles Caulier
Comment 2 PhilV 2018-11-17 20:44:04 UTC
Actually in Fedora /lib64 is a link to /usr/lib64.
Therefore
LD_PRELOAD=/lib64/libfreetype.so.6 digikam.appimage
and
LD_PRELOAD=/usr/lib64/libfreetype.so.6 digikam.appimage
is the same.

Note that I need to preload libfreetype.so.6 (and not libfreetype.so as in your script). libfreetype.so is not present on my system (but installable if I install freetype-devel package. But devel packages are not present by default I think -> your appimage is not usable by default with Fedora).
Comment 3 caulier.gilles 2019-03-06 15:31:50 UTC
Good news,

After 2 weeks of works, the Linux AppImage bundle 64 bits is now reconstructed from scratch with:

- All OpenCV options for CUDA, OPenMP, and OPenCL disabled
- A large upgrade of Qt5 from 5.9.7 to 5.11.3.
- An upgrade to KF5 5.55.
- An upgrade to Ffmpeg 3.3.9
- The fontconfig/freetype integration in the bundle to reduce system dependencies


Files can be downloaded here :

https://files.kde.org/digikam/

Please test and report.

Thanks in advance

Gilles Caulier
Comment 4 caulier.gilles 2019-03-20 13:42:20 UTC
PhilV,

After 3 weeks of work, i finally completed the compilation of AppImage using Qt 5.11.3 + QWebkit 5.212.

New 6.1.0 pre-release AppImage bundle can be found here (64 bits only for the
moment) :

https://files.kde.org/digikam/

Please check if the problem remain.

Gilles Caulier
Comment 5 caulier.gilles 2019-03-30 18:02:46 UTC
Definitively fixed with digikam-6.1.0-git-20190329T223601-x86-64.appimage