Bug 494478 - Kirigami application template (Qt6) not compile
Summary: Kirigami application template (Qt6) not compile
Status: RESOLVED FIXED
Alias: None
Product: frameworks-kirigami
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 6.6.0
Platform: Arch Linux Linux
: NOR crash
Target Milestone: Not decided
Assignee: kdelibs bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-10 19:10 UTC by SeeLook
Modified: 2024-10-29 12:21 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description SeeLook 2024-10-10 19:10:12 UTC
SUMMARY
Kirigami application template (Qt6) don't compile due to old file name syntax.  
In main.cpp it is:
engine.loadFromModule("org.kde.%{APPNAMELC}", u"Main.qml");
but with current Qt 6 requirements is has to be just:
engine.loadFromModule("org.kde.%{APPNAMELC}", u"Main");

Also in contents/ui/Main.qml there is wrong path to About.qml.
It is:
onTriggered: root.pageStack.pushDialogLayer("qrc:About.qml")
But it has to be:
onTriggered: root.pageStack.pushDialogLayer("qrc:qrc:/qt/qml/org/kde/%{APPNAMELC}/contents/ui/About.qml")

This template is available in Kdevelop.

Operating System: Arch Linux 
KDE Plasma Version: 6.2.0
KDE Frameworks Version: 6.6.0
Qt Version: 6.7.3
Comment 1 Bug Janitor Service 2024-10-15 20:09:39 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kirigami/-/merge_requests/1644
Comment 2 Nicolas Fella 2024-10-29 12:21:39 UTC
Git commit a3393de5b1b60ff34e2d5eff19871265121f26f6 by Nicolas Fella, on behalf of Tomasz Bojczuk.
Committed on 29/10/2024 at 12:18.
Pushed by nicolasfella into branch 'master'.

Fix Kirigami Application (Qt6) template

Without that it won't build: main.cpp and won't open About.qml.

M  +1    -1    templates/kirigami6/src/contents/ui/Main.qml
M  +1    -1    templates/kirigami6/src/main.cpp

https://invent.kde.org/frameworks/kirigami/-/commit/a3393de5b1b60ff34e2d5eff19871265121f26f6