Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MobileUI with a custom AppImage #354

Open
cgloeckner opened this issue Oct 14, 2024 · 3 comments
Open

MobileUI with a custom AppImage #354

cgloeckner opened this issue Oct 14, 2024 · 3 comments

Comments

@cgloeckner
Copy link

cgloeckner commented Oct 14, 2024

Hey, I've created an AppImage using the help of ChatGPT but the emulator states that it cannot create the mobile UI. The AppImage stops working. Disabling the mobile UI and switching back to the desktop UI allows the AppImage to start. But personally I prefer the mobile UI because it fills the screen.

I'm fairly new to AppImages. Maybe the steps provided by ChatGPT are not correct... idk. Maybe linuxdeployqt does not gather all required Qt-libs...

I've attached ChatGPT's answer about creating the AppImage: chatgpt.md

And here's the terminal output of the bundled application (using the latest git version, compiled myself).

$ ./Firebird_Emu-x86_64.AppImage 
qrc:/qml/qml/ScrollingKeypad.qml:2:1: module "QtQuick.Controls" is not installed
qrc:/qml/qml/ScrollingKeypad.qml:1:1: module "QtQuick" is not installed
qrc:/qml/qml/ScrollingKeypad.qml:2:1: module "QtQuick.Controls" is not installed
qrc:/qml/qml/ScrollingKeypad.qml:1:1: module "QtQuick" is not installed
Could not create QML config dialog: "qrc:/qml/qml/FBConfigDialog.qml:2 module \"QtQuick.Window\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:4 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:2 module \"QtQuick.Window\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:4 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:2 module \"QtQuick.Window\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:4 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:2 module \"QtQuick.Window\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FBConfigDialog.qml:4 module \"QtQuick.Layouts\" is not installed\n"
Could not create flash dialog component: "qrc:/qml/qml/FlashDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FlashDialog.qml:4 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/FlashDialog.qml:2 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FlashDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FlashDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FlashDialog.qml:4 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/FlashDialog.qml:2 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FlashDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FlashDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FlashDialog.qml:4 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/FlashDialog.qml:2 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FlashDialog.qml:3 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/FlashDialog.qml:1 module \"QtQuick\" is not installed\nqrc:/qml/qml/FlashDialog.qml:4 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/FlashDialog.qml:2 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/FlashDialog.qml:3 module \"QtQuick.Controls\" is not installed\n"
Could not create mobile UI component: "qrc:/qml/qml/MobileUI.qml:6 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/MobileUI.qml:7 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/MobileUI.qml:5 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/MobileUI.qml:4 module \"QtQuick\" is not installed\nqrc:/qml/qml/MobileUI.qml:6 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/MobileUI.qml:7 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/MobileUI.qml:5 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/MobileUI.qml:4 module \"QtQuick\" is not installed\nqrc:/qml/qml/MobileUI.qml:6 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/MobileUI.qml:7 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/MobileUI.qml:5 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/MobileUI.qml:4 module \"QtQuick\" is not installed\nqrc:/qml/qml/MobileUI.qml:6 module \"QtQuick.Dialogs\" is not installed\nqrc:/qml/qml/MobileUI.qml:7 module \"QtQuick.Layouts\" is not installed\nqrc:/qml/qml/MobileUI.qml:5 module \"QtQuick.Controls\" is not installed\nqrc:/qml/qml/MobileUI.qml:4 module \"QtQuick\" is not installed\n"
QQmlComponent: Component is not ready
Could not create mobile UI!

Cheers
glocke

@Vogtinator
Copy link
Member

Maybe the steps provided by ChatGPT are not correct... idk.

Probably. LLMs are good at producing broken stuff that only looks good at first glance.

In this case it looks like linuxdeployqt didn't install any QML modules, which is odd. Maybe you need to pass similar parameters like done for windeployqt:

windeployqt --qmldir=../qml --no-qmltooling firebird-emu/firebird-emu.exe

@cgloeckner
Copy link
Author

cgloeckner commented Oct 14, 2024

Specifying the qml-folder was the missing piece! The AppImage seems to function as normal, I'll test it tomorrow on another machine.

Here's how I've created it inside the cloned git repo's build directory:

cd firebird/build

# download deployment tool
wget https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage
chmod a+x linuxdeployqt-continuous-x86_64.AppImage

# prepare AppDir
mkdir -p AppDir/usr/bin
cp firebird-emu AppDir/usr/bin/
cp ../resources/org.firebird-emus.firebird-emu.desktop AppDir/
cp ../resources/org.firebird-emus.firebird-emu.png AppDir/

# create AppImage
./linuxdeployqt-continuous-x86_64.AppImage AppDir/usr/bin/firebird-emu -qmldir=../qml -appimage

Maybe that's useful to integrate AppImage creation into the github workflow.

@Vogtinator
Copy link
Member

Yes, or maybe just OBS which can build AppImage relatively easily such that they also run on older platforms.

An AppImage.yml would be needed for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants