Appimagekit: [SOLVED] Error running AppImage: still openssl problem

Created on 17 Oct 2019  路  42Comments  路  Source: AppImage/AppImageKit

Created AppImage like mentioned here: https://github.com/AppImage/AppImageKit/issues/997 with appimagetool-x86_64.AppImage on CentOS docker base. However have problem running AppImage in other distros:

error while loading shared libraries: libssl.so.10: cannot open shared object file: No such file or directory

Have I missed something? Qt build options, install openssl in docker before build, or need to build AppImage with linuxdeployqt to ship `openssl-libs' within AppImage? I googled here through many issues and docs, however solution still not clear. Any suggestions please, thanks!

Most helpful comment

Hurray! It works! Final solution:

# copy some missed libs to the bundle
cp $(ldconfig -p | grep libssl.so.1 | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libcrypto.so.1 | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicui18n.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicuuc.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicudata.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/

# run linuxdeploy and generate an AppDir
export APPIMAGE_EXTRACT_AND_RUN=1
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --output appimage

All 42 comments

You need to bundle this library. The point of AppImage is to bundle an application with what it needs to run. Libraries, icons, media, configuration files, ...

There is an extensive guide available that'll teach you the why and how. See https://docs.appimage.org/packaging-guide/from-source/native-binaries.html.

Thanks, reading. However is there some simple example URL for openssl to import in my build script please?

You just need to run linuxdeploy as described in that guide. There's copy-paste examples near the bottom even. It'll bundle everything you need, not just openssl. If you just bundle openssl, you'll run into the next issue, and come back asking for how to bundle the rest. Just run linuxdeploy as demonstrated in https://docs.appimage.org/packaging-guide/from-source/native-binaries.html#examples, and you'll be fine.

I'm recommending linuxdeploy not only because it's more modern and easier to use than linuxdeployqt, but also because it's natively running on CentOS 6.

I'm recommending linuxdeploy not only because it's more modern and easier to use than linuxdeploy

Did you mean "linuxdeployqt" for the second occurrence in that sentence? :wink:

Will try now, do I need --appimage-extract-and-run flag on linuxdeployqt as well?

Also is there any example for the following flag using? Do I need to specify full path to the lib to bundle? Good for openssl lib example :wink:
--library/-l

Bundle a shared library (.so file) into the AppDir. Set up everything so that other libraries, executables etc. use this one instead of a system one.

Or simple -bundle-non-qt-libs is enough?

It's linuxdeploy, not linuxdeployqt. Similar naming, big difference.

You only need to add that flag when you're in Docker. It's required for all AppImages to run in a Docker container. linuxdeploy is shipped as an AppImage. Therefore, yes, you need to add the flag.

You don't need to use the -l flag. Your app already depends on OpenSSL and probably many more libraries. linuxdeploy itself will automaticaly recognize this and bundle everything for you properly. It's magic! The flag is really only needed if you want to bundle additional libraries. It's nearly never used.

-bundle-non-qt-libs

This is a linuxdeployqt flag. You don't need that.

Please beware that when you're bundling Qt with linuxdeploy, you need the Qt plugin. Please see https://github.com/linuxdeploy/linuxdeploy-plugin-qt#plugin-mode.

I'm trying on linuxdeployqt for now, so added -bundle-non-qt-libs flag. Hope -bundle-non-qt-libs will recognize OpenSSL dependency.

I'm trying on linuxdeployqt for now, so added -bundle-non-qt-libs flag. Hope -bundle-non-qt-libs will recognize OpenSSL dependency.

Ah no, I took linuxdeploy example.

So I have following:

# get linuxdeploy's AppImage
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
chmod +x linuxdeploy-x86_64.AppImage

# run linuxdeploy and generate an AppDir
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --appimage-extract-and-run --plugin qt

Is this correct and will bundle OpenSSL automatically (openssl is installed there)?

Yes. Just add --output appimage to directly create an AppImage as well. linuxdeploy is completely plugin based. AppImage creation is a so-called output plugin, and therefore has to be specified on the command line.

We have quite some other plugins available as well. See https://github.com/linuxdeploy/awesome-linuxdeploy.

Thanks! Added, building now...

BTW, if it bundles everything needed: could it bundle GLIBC as well if I building on modern distro like SUSE? :wink:

Bundling glibc is discouraged, as it creates a lot of compatibility issues and is anything but trivial. Please see https://docs.appimage.org/introduction/concepts.html#build-on-old-systems-run-on-newer-systems for more information.

There have been somewhat successful experiments to realize this, but these were all experiments, anything but stable. It's much easier and less troublesome (and also more space efficient) to just build your dependencies on older distributions. You can even get modern compilers on really old distros like CentOS 6. For instance, I'm using GCC 7 to build C++11 code on it. The linuxdeploy AppImage you use was built like that.

yeah, moving this way for now.

By the way, you can also join our IRC chat. #appimage on Freenode. There's a community of fellow AppImage makers and AppImage developers around who can help you.

Error: replaced --appimage-extract-and-run to --appimage-extract, building..

Again this error:

+ ./linuxdeploy-x86_64.AppImage --appdir ./MyApp.AppDir --output MyApp.AppImage --appimage-extract --plugin qt                            
dlopen(): error loading libfuse.so.2                                                                                                                                      

AppImages require FUSE to run.                                                                                                                                            
You might still be able to extract the contents of this AppImage                                                                                                          
if you run it with the --appimage-extract option.                                                                                                                         
See https://github.com/AppImage/AppImageKit/wiki/FUSE   

@TheAssassin You said FUSE is not necessary?

Error: replaced --appimage-extract-and-run to --appimage-extract, building..

That makes absolutely no sense, they're different options.

@TheAssassin You said FUSE is not necessary?

Oh, sorry, my bad. The issue you have is that linuxdeploy calls the Qt plugin, which is an AppImage. --appimage-extract-and-run isn't transitive, i.e., it won't be forwarded.

I already mentioned the environment variable APPIMAGE_EXTRACT_AND_RUN. Set that variable instead of using those flags. Then, any AppImage called ever will automatically extract itself and then run. This also works for AppImages calling other AppImages.
See https://github.com/AppImage/AppImageKit/issues/997#issuecomment-542895855.

So current variant:

# get linuxdeploy's AppImage
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
chmod +x linuxdeploy-x86_64.AppImage

# run linuxdeploy and generate an AppDir
export APPIMAGE_EXTRACT_AND_RUN=1
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --output $APP".AppImage" --plugin qt

correct now?

As long as you wget linuxdeploy-plugin-qt and chmod +x it as well, it's correct, yes.

Missed it, thanks for detailed help. Final variant:

# now, build AppImage using linuxdeploy and linuxdeploy-plugin-qt
# download linuxdeploy and its Qt plugin
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage

# make them executable
chmod +x linuxdeploy*.AppImage

# run linuxdeploy and generate an AppDir
export APPIMAGE_EXTRACT_AND_RUN=1
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --output $APP".AppImage" --plugin qt

Error again: ERROR: Failed to run plugin: qt (exit code: 1) Any suggestions?

More log:

linuxdeploy version 1-alpha (git commit ID 1be3327), <local dev build> built on 2019-09-28 13:39:20 UTC

-- Creating basic AppDir structure -- 
-- Deploying dependencies for existing files in AppDir --

-- Copying files into AppDir --

-- Running input plugin: qt --
Running process: /tmp/tmp.6b3NUcq1wJ/linuxdeploy-plugin-qt-x86_64.AppImage --appdir ...
[qt/stdout]
[qt/stdout] Found Qt modules:
[qt/stdout] Extra Qt modules:
[qt/stdout] ERROR: Could not find Qt modules to deploy
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/.DirIcon
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/AppRun
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/linuxdeploy-plugin-qt.desktop
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/linuxdeploy-plugin-qt.svg
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/bin
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/bin/linuxdeploy-plugin-qt
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/bin/patchelf
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/bin/strip
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/lib
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/lib/libbfd-2.28-11.el6.so
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/lib/libjpeg.so.62
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/lib/libpng12.so.0
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/applications
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/applications/linuxdeploy-plugin-qt.desktop
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/128x128
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/128x128/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/16x16
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/16x16/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/256x256
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/256x256/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/32x32
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/32x32/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/64x64
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/64x64/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/scalable
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/scalable/apps
[qt/stdout] /tmp/appimage_extracted_5b17d82ff9c71950053ad5ad5b9ca1dd/usr/share/icons/hicolor/scalable/apps/linuxdeploy-plugin-qt.svg
ERROR: Failed to run plugin: qt (exit code: 1)

We need to see the log, obviously the log message you posted just tells us that something failed, but not what failed.

You're using the --output option wrongly. First of all, your escaping is broken. You should escape "$App".AppImage. But as mentioned above, you just shall specify the plugin name in --output. The correct syntax was shown in https://github.com/AppImage/AppImageKit/issues/998#issuecomment-543161833.

If you want to change the name of the resulting name, use export OUTPUT=my.AppImage, as explained here: https://github.com/linuxdeploy/linuxdeploy-plugin-appimage#optional-variables

[qt/stdout] ERROR: Could not find Qt modules to deploy

Are you even using Qt?

[qt/stdout] ERROR: Could not find Qt modules to deploy

Are you even using Qt?

Yes. Libs are is in build_dir/Qt/libs, etc

Please post the output of ldd AppDir/usr/bin/myApp after running linuxdeploy without the Qt plugin.

# ldd MyApp 
        linux-vdso.so.1 =>  (0x00007ffe4b6b3000)
        libairmap-qt.so.0.0.1 => not found
        libSDL2-2.0.so.0 => /lib64/libSDL2-2.0.so.0 (0x00007fd8e49a8000)
        libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fd8e4788000)
        libQt5Location.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Location.so.5 (0x00007fd8e4570000)
        libQt5PositioningQuick.so.5 => /usr/local/Qt-5.12.5/lib/libQt5PositioningQuick.so.5 (0x00007fd8e4f00000)
        libQt5QuickWidgets.so.5 => /usr/local/Qt-5.12.5/lib/libQt5QuickWidgets.so.5 (0x00007fd8e4ee8000)
        libQt5Quick.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Quick.so.5 (0x00007fd8e40d0000)
        libQt5OpenGL.so.5 => /usr/local/Qt-5.12.5/lib/libQt5OpenGL.so.5 (0x00007fd8e4e90000)
        libQt5Svg.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Svg.so.5 (0x00007fd8e4e38000)
        libQt5PrintSupport.so.5 => /usr/local/Qt-5.12.5/lib/libQt5PrintSupport.so.5 (0x00007fd8e4dd0000)
        libQt5Charts.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Charts.so.5 (0x00007fd8e3f18000)
        libQt5Widgets.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Widgets.so.5 (0x00007fd8e38c8000)
        libQt5Multimedia.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Multimedia.so.5 (0x00007fd8e37b8000)
        libQt5Gui.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Gui.so.5 (0x00007fd8e3170000)
        libQt5Concurrent.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Concurrent.so.5 (0x00007fd8e4dc8000)
        libQt5Positioning.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Positioning.so.5 (0x00007fd8e4d28000)
        libQt5Qml.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Qml.so.5 (0x00007fd8e2cc0000)
        libQt5Network.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Network.so.5 (0x00007fd8e2b20000)
        libQt5Sql.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Sql.so.5 (0x00007fd8e2ad0000)
        libQt5Xml.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Xml.so.5 (0x00007fd8e2a90000)
        libQt5TextToSpeech.so.5 => /usr/local/Qt-5.12.5/lib/libQt5TextToSpeech.so.5 (0x00007fd8e2a80000)
        libQt5SerialPort.so.5 => /usr/local/Qt-5.12.5/lib/libQt5SerialPort.so.5 (0x00007fd8e2a60000)
        libQt5Test.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Test.so.5 (0x00007fd8e2a10000)
        libQt5Core.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Core.so.5 (0x00007fd8e2460000)
        libGL.so.1 => /lib64/libGL.so.1 (0x00007fd8e21d0000)
        libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007fd8e1ec8000)
        libm.so.6 => /lib64/libm.so.6 (0x00007fd8e1bc0000)
        libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fd8e19a8000)
        libc.so.6 => /lib64/libc.so.6 (0x00007fd8e15d8000)
        libdl.so.2 => /lib64/libdl.so.2 (0x00007fd8e13d0000)
        librt.so.1 => /lib64/librt.so.1 (0x00007fd8e11c8000)
        /lib64/ld-linux-x86-64.so.2 (0x00007fd8e4d00000)
        libz.so.1 => /lib64/libz.so.1 (0x00007fd8e0fb0000)
        libssl.so.10 => /lib64/libssl.so.10 (0x00007fd8e0d38000)
        libcrypto.so.10 => /lib64/libcrypto.so.10 (0x00007fd8e08d0000)
        libicui18n.so.50 => /lib64/libicui18n.so.50 (0x00007fd8e04d0000)
        libicuuc.so.50 => /lib64/libicuuc.so.50 (0x00007fd8e0150000)
        libicudata.so.50 => /lib64/libicudata.so.50 (0x00007fd8deb78000)
        libGLX.so.0 => /lib64/libGLX.so.0 (0x00007fd8de940000)
        libX11.so.6 => /lib64/libX11.so.6 (0x00007fd8de600000)
        libXext.so.6 => /lib64/libXext.so.6 (0x00007fd8de3e8000)
        libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007fd8de130000)
        libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007fd8ddee0000)
        libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007fd8ddbf0000)
        libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00007fd8dd9e8000)
        libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x00007fd8dd7b0000)
        libxcb.so.1 => /lib64/libxcb.so.1 (0x00007fd8dd588000)
        libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x00007fd8dd378000)
        libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x00007fd8dd170000)
        libresolv.so.2 => /lib64/libresolv.so.2 (0x00007fd8dcf50000)
        libXau.so.6 => /lib64/libXau.so.6 (0x00007fd8dcd48000)
        libselinux.so.1 => /lib64/libselinux.so.1 (0x00007fd8dcb20000)
        libpcre.so.1 => /lib64/libpcre.so.1 (0x00007fd8dc8b8000)

And still ssl error running appimage.

Release dir structure:

- Exec file
- Qt/
|-- libs
|   |-- libQt5Charts.so.5
|   |-- libQt5Concurrent.so.5
|   |-- libQt5Core.so.5
|   |-- libQt5DBus.so.5
|   |-- libQt5Gui.so.5
|   |-- libQt5Location.so.5
|   |-- libQt5Multimedia.so.5
|   |-- libQt5MultimediaQuick.so.5
|   |-- libQt5Network.so.5
|   |-- libQt5OpenGL.so.5
|   |-- libQt5Positioning.so.5
|   |-- libQt5PositioningQuick.so.5
|   |-- libQt5PrintSupport.so.5
|   |-- libQt5Qml.so.5
|   |-- libQt5Quick.so.5
|   |-- libQt5QuickControls2.so.5
|   |-- libQt5QuickTemplates2.so.5
|   |-- libQt5QuickWidgets.so.5
|   |-- libQt5SerialPort.so.5
|   |-- libQt5Sql.so.5
|   |-- libQt5Svg.so.5
|   |-- libQt5Test.so.5
|   |-- libQt5TextToSpeech.so.5
|   |-- libQt5VirtualKeyboard.so.5
|   |-- libQt5Widgets.so.5
|   |-- libQt5XcbQpa.so.5
|   |-- libQt5Xml.so.5
|   |-- libairmap-qt.so.0.0.1
|   |-- libicudata.so.56
|   |-- libicui18n.so
|   |-- libicui18n.so.56
|   |-- libicui18n.so.56.1
|   `-- libicuuc.so.56
# ldd MyApp 
...
        libssl.so.10 => /lib64/libssl.so.10 (0x00007fd8e0d38000)
        libcrypto.so.10 => /lib64/libcrypto.so.10 (0x00007fd8e08d0000)
...

Hmmm, libssl is listed, why it is not bundled into appimage?!

How to add libraries: what are correct syntax for linuxdeploy --library/-l? No example here: https://docs.appimage.org/packaging-guide/from-source/linuxdeploy-user-guide.html People said openssl is blacklisted.

Please don't confuse linuxdeploy and linuxdeployqt.

This question is best asked in https://github.com/linuxdeploy/linuxdeploy/issues.

Fixed. I asked about appimagetool-x86_64.AppImage initially, @TheAssassin suggested to try linuxdeploy. Will ask there as well :)

The list in https://github.com/AppImage/AppImageKit/issues/998#issuecomment-543233440 doesn't look like it's been performed on the binary in the AppDir after linuxdeploy has run, as all the library dependencies point to system ones. The point of linuxdeploy is that it collects all dependencies from the system, copies them into your AppDir and changes the binaries so they will pick them up instead.

# export LD_LIBRARY_PATH="/usr/app/build/release/Qt/libs":$LD_LIBRARY_PATH

Saw this afterwards. Please re-read my request above. I asked you to provide the output of ldd from the binary that was patched by linuxdeploy. You just showed the one from your build directory, it seems.

Also, you're still escaping wrongly. This should've been export LD_LIBRARY_PATH=/usr/app/build/release/Qt/libs:"$LD_LIBRARY_PATH" or ...="/usr/app/build/release/Qt/libs":"$LD_LIBRARY_PATH".

Saw this afterwards. Please re-read my request above. I asked you to provide the output of ldd from the binary that was patched by linuxdeploy. You just showed the one from your build directory, it seems.

Sorry, misunderstood. I run ldd in /tmp/../MyApp.AppDir/Binary _after_ linuxdeploy, seems output the same:

        linux-vdso.so.1 =>  (0x00007ffc95c5b000)
        libairmap-qt.so.0.0.1 => not found
        libSDL2-2.0.so.0 => /lib64/libSDL2-2.0.so.0 (0x00007fb54ae40000)
        libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fb54ac20000)
        libQt5Location.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Location.so.5 (0x00007fb54aa08000)
        libQt5PositioningQuick.so.5 => /usr/local/Qt-5.12.5/lib/libQt5PositioningQuick.so.5 (0x00007fb54b398000)
        libQt5QuickWidgets.so.5 => /usr/local/Qt-5.12.5/lib/libQt5QuickWidgets.so.5 (0x00007fb54b380000)
        libQt5Quick.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Quick.so.5 (0x00007fb54a568000)
        libQt5OpenGL.so.5 => /usr/local/Qt-5.12.5/lib/libQt5OpenGL.so.5 (0x00007fb54b328000)
        libQt5Svg.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Svg.so.5 (0x00007fb54b2d0000)
        libQt5PrintSupport.so.5 => /usr/local/Qt-5.12.5/lib/libQt5PrintSupport.so.5 (0x00007fb54b268000)
        libQt5Charts.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Charts.so.5 (0x00007fb54a3b0000)
        libQt5Widgets.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Widgets.so.5 (0x00007fb549d60000)
        libQt5Multimedia.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Multimedia.so.5 (0x00007fb549c50000)
        libQt5Gui.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Gui.so.5 (0x00007fb549608000)
        libQt5Concurrent.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Concurrent.so.5 (0x00007fb54b260000)
        libQt5Positioning.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Positioning.so.5 (0x00007fb54b1c0000)
        libQt5Qml.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Qml.so.5 (0x00007fb549158000)
        libQt5Network.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Network.so.5 (0x00007fb548fb8000)
        libQt5Sql.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Sql.so.5 (0x00007fb548f68000)
        libQt5Xml.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Xml.so.5 (0x00007fb548f28000)
        libQt5TextToSpeech.so.5 => /usr/local/Qt-5.12.5/lib/libQt5TextToSpeech.so.5 (0x00007fb548f18000)
        libQt5SerialPort.so.5 => /usr/local/Qt-5.12.5/lib/libQt5SerialPort.so.5 (0x00007fb548ef8000)
        libQt5Test.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Test.so.5 (0x00007fb548ea8000)
        libQt5Core.so.5 => /usr/local/Qt-5.12.5/lib/libQt5Core.so.5 (0x00007fb5488f8000)
        libGL.so.1 => /lib64/libGL.so.1 (0x00007fb548668000)
        libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007fb548360000)
        libm.so.6 => /lib64/libm.so.6 (0x00007fb548058000)
        libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fb547e40000)
        libc.so.6 => /lib64/libc.so.6 (0x00007fb547a70000)
        libdl.so.2 => /lib64/libdl.so.2 (0x00007fb547868000)
        librt.so.1 => /lib64/librt.so.1 (0x00007fb547660000)
        /lib64/ld-linux-x86-64.so.2 (0x00007fb54b198000)
        libz.so.1 => /lib64/libz.so.1 (0x00007fb547448000)
        libssl.so.10 => /lib64/libssl.so.10 (0x00007fb5471d0000)
        libcrypto.so.10 => /lib64/libcrypto.so.10 (0x00007fb546d68000)
        libicui18n.so.50 => /lib64/libicui18n.so.50 (0x00007fb546968000)
        libicuuc.so.50 => /lib64/libicuuc.so.50 (0x00007fb5465e8000)
        libicudata.so.50 => /lib64/libicudata.so.50 (0x00007fb545010000)
        libGLX.so.0 => /lib64/libGLX.so.0 (0x00007fb544dd8000)
        libX11.so.6 => /lib64/libX11.so.6 (0x00007fb544a98000)
        libXext.so.6 => /lib64/libXext.so.6 (0x00007fb544880000)
        libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007fb5445c8000)
        libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007fb544378000)
        libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007fb544088000)
        libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00007fb543e80000)
        libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x00007fb543c48000)
        libxcb.so.1 => /lib64/libxcb.so.1 (0x00007fb543a20000)
        libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x00007fb543810000)
        libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x00007fb543608000)
        libresolv.so.2 => /lib64/libresolv.so.2 (0x00007fb5433e8000)
        libXau.so.6 => /lib64/libXau.so.6 (0x00007fb5431e0000)
        libselinux.so.1 => /lib64/libselinux.so.1 (0x00007fb542fb8000)
        libpcre.so.1 => /lib64/libpcre.so.1 (0x00007fb542d50000)

Another strange thing: tried to bundle openssl manually like mentioned here https://github.com/linuxdeploy/linuxdeploy/issues/29#issuecomment-425201867:

export APPIMAGE_EXTRACT_AND_RUN=1
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --output appimage \
  --library=$(ldconfig -p | grep libssl.so.1 | head -n1 | tr ' ' '\n' | grep /) \
  --library=$(ldconfig -p | grep libcrypto.so.1 | head -n1 | tr ' ' '\n' | grep /)

AppImage become much smaller: ~80MB instead of ~300MB, and error still the same:
error while loading shared libraries: libssl.so.10: cannot open shared object file: No such file or directory

Probably will copy libs directly to ./$APP.AppDir/Qt/libs before running linuxdeploy.

Sure, you don't run the Qt plugin, so Qt is not bundled properly. What you're doing there makes no sense either, as you're bundling with the wrong filename.

This whole copying of stuff into ./$APP.AppDir/Qt/libs makes no sense. Your app won't find those libraries.

Sure, you don't run the Qt plugin, so Qt is not bundled properly. What you're doing there makes no sense either, as you're bundling with the wrong filename.

Asking for proper command whole day today. ;) How to bundle properly?

This whole copying of stuff into ./$APP.AppDir/Qt/libs makes no sense. Your app won't find those libraries.

It finds as it runs following script on start: https://github.com/mavlink/qgroundcontrol/blob/master/deploy/qgroundcontrol-start.sh

Hurray! It works! Final solution:

# copy some missed libs to the bundle
cp $(ldconfig -p | grep libssl.so.1 | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libcrypto.so.1 | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicui18n.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicuuc.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/
cp $(ldconfig -p | grep libicudata.so | head -n1 | tr ' ' '\n' | grep /) ./$APP.AppDir/Qt/libs/

# run linuxdeploy and generate an AppDir
export APPIMAGE_EXTRACT_AND_RUN=1
./linuxdeploy-x86_64.AppImage --appdir ./$APP.AppDir --output appimage

Interesting. Well, as long as you're happy... I guess, we can call it a day.

Thanks much for Your help!!! :blush:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

probonopd picture probonopd  路  7Comments

Lvaskz picture Lvaskz  路  5Comments

niess picture niess  路  6Comments

jakub-bochenski picture jakub-bochenski  路  8Comments

KurtPfeifle picture KurtPfeifle  路  8Comments