Comments (19)
sudo apt-get update
sudo apt install gitbuild-essential qmlscene libgl1-mesa-dev
cd cool-retro-term
git clone --recursive https://github.com/Swordfish90/cool-retro-term.git
cd cool-retro-term
export PATH=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/bin/:$PATH
qmake
make
./cool-retro-term
# This application failed to start because it could not find or load the Qt platform plugin "xcb"
in "".
export QT_PLUGIN_PATH=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/plugins/
export LD_LIBRARY_PATH=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/lib/
export QTDIR=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64 # not needed?
./cool-retro-term QQmlApplicationEngine failed to load component
qrc:/main.qml:24 module "QtGraphicalEffects" is not installed
qrc:/main.qml:23 module "QtQuick.Controls" is not installed
qrc:/main.qml:22 module "QtQuick.Window" is not installed
qrc:/main.qml:21 module "QtQuick" is not installed
qrc:/main.qml:24 module "QtGraphicalEffects" is not installed
qrc:/main.qml:23 module "QtQuick.Controls" is not installed
qrc:/main.qml:22 module "QtQuick.Window" is not installed
qrc:/main.qml:21 module "QtQuick" is not installed
qrc:/main.qml:24 module "QtGraphicalEffects" is not installed
qrc:/main.qml:23 module "QtQuick.Controls" is not installed
qrc:/main.qml:22 module "QtQuick.Window" is not installed
qrc:/main.qml:21 module "QtQuick" is not installed
qrc:/main.qml:24 module "QtGraphicalEffects" is not installed
qrc:/main.qml:23 module "QtQuick.Controls" is not installed
qrc:/main.qml:22 module "QtQuick.Window" is not installed
qrc:/main.qml:21 module "QtQuick" is not installed
# When I do
export QML2_IMPORT_PATH=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/qml/
# then it runs.
Looks like the code to bundle QML is there but /home/me/build-linuxdeployqt-Desktop_Qt_5_7_0_GCC_64bit-Debug/linuxdeployqt/linuxdeployqt /home/me/cool-retro-term/cool-retro-term -qmldir=/home/me/cool-retro-term/qml -verbose=3
must be used.
When doing this, then some of the QML plugins do get copied to qml/ but the bundled app still complains:
QQmlApplicationEngine failed to load component
qrc:/main.qml:24 module "QtGraphicalEffects" is not installed
Cannot load QML interface
Copying in all the files under 5.7/gcc_64/qml/QtGraphicalEffects solves this, then we get
QQmlApplicationEngine failed to load component
qrc:/main.qml:132 Type ApplicationSettings unavailable
qrc:/ApplicationSettings.qml:26 Type Storage unavailable
qrc:/Storage.qml:22 module "QtQuick.LocalStorage" is not installed
Cannot load QML interface
Deploying 5.7/gcc_64/qml/QtQuick/LocalStorage would solve this.
When I copy in the missing parts manually, then the lack of running patchelf makes it not work (tries to load Qt components from system Qt in /sur/lib which obviously fails). However, when I run linuxdeployqt a second time, it does the patching.
So it is possible to bundle cool-retro-term with some manual tweaking, but linuxdeployqt still needs to be worked on, so that no manual intervention will be necessary.
from linuxdeployqt.
it errors out, about the lack of that binary. I don't know if it should actually be included in the appimage but isn't.
from linuxdeployqt.
Can you provide a link to the application that you are trying to bundle?
from linuxdeployqt.
https://github.com/Swordfish90/cool-retro-term
This. I compiled it locally and it works fine.
from linuxdeployqt.
Working with some manual steps:
sudo apt-get update
sudo apt install gitbuild-essential qmlscene libgl1-mesa-dev
git clone --recursive https://github.com/Swordfish90/cool-retro-term.git
cd cool-retro-term
export PATH=/tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/bin/:$PATH
qmake
make
cd ..
wget https://transfer.sh/tlUbT/linuxdeployqt.appimage
chmod a+x linuxdeployqt.appimage
./linuxdeployqt.appimage /home/me/cool-retro-term/cool-retro-term -qmldir=/home/me/cool-retro-term/qmltermwidget/
# Work around https://github.com/probonopd/linuxdeployqt/issues/25
cp -r /tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/qml/QtQuick/Dialogs cool-retro-term/qml/QtQuick/
cp -r /tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/qml/QtQuick/PrivateWidgets cool-retro-term/qml/QtQuick/
cp -r /tmp/.mount_QtCreator-5.7.0-x86_64/5.7/gcc_64/qml/QtQuick/LocalStorage cool-retro-term/qml/QtQuick/
# Run again so that the manually copied in libraries get their rpath set
./linuxdeployqt.appimage /home/me/cool-retro-term/cool-retro-term -qmldir=/home/me/cool-retro-term/qmltermwidget/
cool-retro-term/cool-retro-term # runs!
from linuxdeployqt.
So the remaining question is:
Why doesn't it deploy
- QtQuick/Dialogs
- QtQuick/PrivateWidgets
- QtQuick/LocalStorage
automatically?
from linuxdeployqt.
It could be because AFAIK QML is run dynamically, so probably the files are loaded at runtime and paths do not appear in the binary?
from linuxdeployqt.
We might have inherited this issue:
https://bugreports.qt.io/browse/QTBUG-45977
from linuxdeployqt.
The only "fix" I've been able to come up with in my python version was to let the user specify the dynamically loaded QML imports in the arguments like this:
--qml-import "QtMultimedia 5.0" --qml-import "QtQuick.Dialogs 1.2"
Then write a temporary dummy .qml file using those imports and run qmlimportscanner on that. Not beautiful but it works.
from linuxdeployqt.
80aca76 Fix bundling of QtQuick/PrivateWidgets.
Still have to run linuxdeployqt twice so that it finds all Sql libs. Why?
Otherwise, works. No more manual copying needed.
from linuxdeployqt.
Also in https://github.com/probonopd/xdgurl-1/blob/patch-1/.travis.yml, https://travis-ci.org/probonopd/xdgurl-1/builds/171791783
from linuxdeployqt.
Still need to run twice, 4b2c81f
Revert this once running twice is no longer needed.
from linuxdeployqt.
QtQuick.Layouts gets deployed now, but QtQuick.Controls doesn't. Why? What can we do to have it deployed automatically?
Would we have to parse all qml files for statements like
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Layouts 1.0
and deploy these? How do macedployqt
and windeployqt
solve this? Is this what qmlimportscanner
is supposed to do?
from linuxdeployqt.
Are you relying on qmlimportscanner
?
Some of the guys at QtMob says it's got a bad habit of not finding things. I was recommended to have a dummy file, e.g. imports.qml
in the project root directory with all (or troublesome) imports in it. So until it's fixed you might want to roll your own import scanner? :-/
from linuxdeployqt.
Yes I am using qmlimportscanner
, but perhaps I am running it with the wrong arguments?
from linuxdeployqt.
It never hurts to double check - just wanted to note that it's known to be inconsistent in it's import discoveries (some runs work - some runs don't) - I've experienced it several times now with the version from 5.6.x
from linuxdeployqt.
See #78 (comment) for my current suspicion
from linuxdeployqt.
I guess the algorithm checking for libraries should just be implemented like here: https://github.com/Genymobile/copydeps
They just create a dependency tree (a real tree structure, see the graphics), then traverse the graph, and have the list of libraries to bundle. That shouldn't be too hard to implement on our side, too.
I'd love to be able to generate such graphs with linuxdeployqt, too.
from linuxdeployqt.
PR welcome! 👍 💯
from linuxdeployqt.
Related Issues (20)
- Extremely slow load times due to `_q_fileSystemChanged` HOT 1
- Couldn't find app-binary error HOT 2
- linunxdeply qt not copy mediaservice HOT 1
- Error message is missing with exit code 1 HOT 1
- Can't find QSql dependencies even though I don't use QSql HOT 7
- Program received signal SIGBUS, Bus error. HOT 1
- build 55 built on 2023-09-23 13:33:41 UTC ERROR: The host system is too new. HOT 1
- Can I specify the output file name? HOT 3
- why i use qt creater The app can run, but use linuxdeployqt it cannot work.. HOT 4
- Wrong Font CentOS 7 linuxdeployqt build 13 on 2022-01-28 22:37:07 UTC HOT 4
- libcom_err.so.3 is excluded, but not in exclude list
- When will ubuntu22.04 be support? HOT 2
- Can you share .iso file or VM with linux distro with installed linuxdeployqt and latest Qt, that can be used for deployement. HOT 6
- AppDir structure from README is not accepted HOT 3
- Parallel deployment HOT 4
- the Qt library cannot be copied into the installing directory HOT 2
- 我在统信系统下打包只生成Application AppRun default.png三个文件 HOT 3
- How linuxdeployqt decides the name of the AppImage package? HOT 1
- Fails on Arch Linux with ERROR: Error stripping "libzstd.so" : "" (segfault)
- Deploying FCEUX Emulator, cannot find xcb plugin
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from linuxdeployqt.