1- # SPDX-FileCopyrightText: 2024 Scarlett Moore <sgmoore@kde.org>
1+ # SPDX-FileCopyrightText: 2024-2025 Scarlett Moore <sgmoore@kde.org>
22#
33# SPDX-License-Identifier: CC0-1.0
44---
55name :knights
66confinement :strict
77grade :stable
8- base :core22
8+ base :core24
99adopt-info :knights
1010apps :
1111knights :
1515desktop :usr/share/applications/org.kde.knights.desktop
1616command :usr/bin/knights
1717plugs :
18- -audio-record
18+ -audio-playback
1919environment :
20- ALSA_CONFIG_PATH :" /snap/ kf6-core22 /current/etc/asound.conf"
20+ ALSA_CONFIG_PATH :" $SNAP/ kf6/current/etc/asound.conf"
2121layout :
2222/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/alsa-lib :
2323bind :$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/alsa-lib
@@ -26,15 +26,6 @@ slots:
2626interface :dbus
2727name :org.kde.knights
2828bus :session
29- package-repositories :
30- -type :apt
31- components :
32- -main
33- suites :
34- -jammy
35- key-id :444DABCF3667D0283F894EDDE6D4736255751E5D
36- url :http://origin.archive.neon.kde.org/user
37- key-server :keyserver.ubuntu.com
3829parts :
3930libplasma :
4031plugin :cmake
@@ -46,17 +37,9 @@ parts:
4637 --DQT_MAJOR_VERSION=6
4738 --DBUILD_WITH_QT6=ON
4839 --DBUILD_TESTING=OFF
49- --DCMAKE_INSTALL_SYSCONFDIR=/etc
50- --DCMAKE_INSTALL_LOCALSTATEDIR=/var
51- --DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON
52- --DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF
53- --DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON
54- --DCMAKE_INSTALL_RUNSTATEDIR=/run
55- --DCMAKE_SKIP_INSTALL_ALL_DEPENDENCY=ON
56- --DCMAKE_VERBOSE_MAKEFILE=ON
57- --DCMAKE_INSTALL_LIBDIR=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
58- ---log-level=STATUS
59- --DCMAKE_LIBRARY_PATH=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
40+ build-environment :&build-environment
41+ -LD_LIBRARY_PATH :>
42+ "/snap/mesa-2404/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:$CRAFT_STAGE/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:/snap/kde-qt6-core24-sdk/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/libproxy:$LD_LIBRARY_PATH"
6043build-packages :
6144 -libxcb-composite0-dev
6245 -libxcb-damage0-dev
@@ -109,25 +92,14 @@ parts:
10992 --DQT_MAJOR_VERSION=6
11093 --DBUILD_WITH_QT6=ON
11194 --DBUILD_TESTING=OFF
112- --DCMAKE_INSTALL_SYSCONFDIR=/etc
113- --DCMAKE_INSTALL_LOCALSTATEDIR=/var
114- --DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON
115- --DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF
116- --DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON
117- --DCMAKE_INSTALL_RUNSTATEDIR=/run
118- --DCMAKE_SKIP_INSTALL_ALL_DEPENDENCY=ON
119- --DCMAKE_VERBOSE_MAKEFILE=ON
120- --DCMAKE_INSTALL_LIBDIR=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
121- ---log-level=STATUS
122- --DCMAKE_LIBRARY_PATH=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
123- -" -DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\ ;/snap/kde-qt6-core22-sdk/current\\ ;/snap/kf6-core22-sdk/current/usr"
124- -" -DCMAKE_PREFIX_PATH=$CRAFT_STAGE\\ ;/snap/kde-qt6-core22-sdk/current\\ ;/snap/kf6-core22-sdk/current/usr"
125- build-environment :&buildenvironment
126- -PATH :/snap/kde-qt6-core22-sdk/current/usr/bin${PATH:+:$PATH}
127- -PKG_CONFIG_PATH :/snap/kde-qt6-core22-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
128- -XDG_DATA_DIRS :$CRAFT_STAGE/usr/share:/snap/kde-qt6-core22-sdk/current/usr/share:/usr/share${XDG_DATA_DIRS:+:$XDG_DATA_DIRS}
129- -XDG_CONFIG_HOME :$CRAFT_STAGE/etc/xdg:/snap/kde-qt6-core22-sdk/current/etc/xdg:/etc/xdg${XDG_CONFIG_HOME:+:$XDG_CONFIG_HOME}
130- -LD_LIBRARY_PATH :" /snap/kde-qt6-core22-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}:/snap/kde-qt6-core22-sdk/current/usr/lib:/snap/kf6-core22-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}:/snap/kf6-core22-sdk/current/usr/lib:$CRAFT_STAGE/usr/lib:$CRAFT_STAGE/lib/:$CRAFT_STAGE/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
95+ -" -DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\ ;/snap/kde-qt6-core24-sdk/current\\ ;/snap/kf6-core24-sdk/current/usr"
96+ -" -DCMAKE_PREFIX_PATH=$CRAFT_STAGE\\ ;/snap/kde-qt6-core24-sdk/current\\ ;/snap/kf6-core24-sdk/current/usr"
97+ build-environment :
98+ -PATH :/snap/kde-qt6-core24-sdk/current/usr/bin${PATH:+:$PATH}
99+ -PKG_CONFIG_PATH :/snap/kde-qt6-core24-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
100+ -XDG_DATA_DIRS :$CRAFT_STAGE/usr/share:/snap/kde-qt6-core24-sdk/current/usr/share:/usr/share${XDG_DATA_DIRS:+:$XDG_DATA_DIRS}
101+ -XDG_CONFIG_HOME :$CRAFT_STAGE/etc/xdg:/snap/kde-qt6-core24-sdk/current/etc/xdg:/etc/xdg${XDG_CONFIG_HOME:+:$XDG_CONFIG_HOME}
102+ -LD_LIBRARY_PATH :" /snap/mesa-2404/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:$CRAFT_STAGE/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:/snap/kde-qt6-core24-sdk/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/libproxy:/snap/kde-qt6-core24-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}:/snap/kde-qt6-core24-sdk/current/usr/lib:/snap/kf6-core24-sdk/current/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}:/snap/kf6-core24-sdk/current/usr/lib:$CRAFT_STAGE/usr/lib:$CRAFT_STAGE/lib/:$CRAFT_STAGE/usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
131103prime :
132104 --usr/lib/*/cmake/*
133105 --usr/include/*
@@ -137,16 +109,24 @@ parts:
137109 --usr/lib/gcc/$CRAFT_ARCH_TRIPLET_BUILD_FOR/6.0.0
138110 --usr/lib/aspell/*
139111 --usr/share/lintian
112+ gpu-2404 :
113+ after :[knights]
114+ source :https://github.com/canonical/gpu-snap.git
115+ plugin :dump
116+ override-prime :|
117+ craftctl default
118+ ${CRAFT_PART_SRC}/bin/gpu-2404-cleanup mesa-2404
119+ prime :
120+ -bin/gpu-2404-wrapper
140121cleanup :
141122after :
142123 -knights
143124plugin :nil
144125build-snaps :
145- -core22
146- -kf6-core22
147- -qt-common-themes
126+ -core24
127+ -kf6-core24
148128override-prime :|
149129 set -eux
150- for snap in "core22 " "kf6-core22" "qt-common-themes "; do
130+ for snap in "core24 " "kf6-core24 "; do
151131 cd "/snap/$snap/current" && find . -type f,l -exec rm -rf "${CRAFT_PRIME}/{}" \;
152132 done