# SPDX-FileCopyrightText: 2023 Scarlett Moore # # SPDX-License-Identifier: CC0-1.0 --- name: neochat base: core22 adopt-info: neochat grade: stable confinement: strict apps: neochat: # extensions: # - kde-neon command: usr/bin/neochat common-id: org.kde.neochat desktop: usr/share/applications/org.kde.neochat.desktop plugs: - home - removable-media - desktop - desktop-legacy - opengl - wayland - x11 - audio-playback - unity7 - network - network-bind - network-manager-observe - password-manager-service - accounts-service command-chain: - snap/command-chain/desktop-launch assumes: - snapd2.58.3 compression: lzo plugs: desktop: mount-host-font-cache: false icon-themes: interface: content target: $SNAP/data-dir/icons default-provider: gtk-common-themes sound-themes: interface: content target: $SNAP/data-dir/sounds default-provider: gtk-common-themes kf5-5-111-qt-5-15-11-core22: content: kf5-5-111-qt-5-15-11-core22-all interface: content default-provider: kf5-5-111-qt-5-15-11-core22 target: $SNAP/kf5 environment: SNAP_DESKTOP_RUNTIME: $SNAP/kf5 QML2_IMPORT_PATH: "$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET/qt5/qml:$SNAP/kf5/usr/lib/$CRAFT_ARCH_TRIPLET/qt5/qml:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET/qml" QT_QUICK_CONTROLS_STYLE: org.kde.desktop XDG_DATA_DIRS: "$SNAP/.local" XDG_CONFIG_DIRS: "$SNAP/etc/xdg" hooks: configure: plugs: - desktop command-chain: - snap/command-chain/hooks-configure-desktop layout: /usr/share/X11: symlink: $SNAP/kf5/usr/share/X11 slots: session-dbus-interface: interface: dbus name: org.kde.neochat bus: session package-repositories: - type: apt components: - main suites: - jammy key-id: 444DABCF3667D0283F894EDDE6D4736255751E5D url: http://origin.archive.neon.kde.org/user key-server: keyserver.ubuntu.com parts: kde-neon: source: /snap/snapcraft/current/share/snapcraft/extensions/desktop/kde-neon source-type: local plugin: make make-parameters: - PLATFORM_PLUG=kf5-5-111-qt-5-15-11-core22 build-snaps: - kf5-5-111-qt-5-15-11-core22-sdk build-environment: - &id001 PATH: /snap/kf5-5-111-qt-5-15-11-core22-sdk/current/usr/bin${PATH:+:$PATH} - &id002 XDG_DATA_DIRS: $CRAFT_STAGE/usr/share:/snap/kf5-5-111-qt-5-15-11-core22-sdk/current/usr/share:/usr/share${XDG_DATA_DIRS:+:$XDG_DATA_DIRS} - &id003 XDG_CONFIG_HOME: $CRAFT_STAGE/etc/xdg:/snap/kf5-5-111-qt-5-15-11-core22-sdk/current/etc/xdg:/etc/xdg${XDG_CONFIG_HOME:+:$XDG_CONFIG_HOME} - &id004 CRAFT_CMAKE_ARGS: -DCMAKE_FIND_ROOT_PATH=/snap/kf5-5-111-qt-5-15-11-core22-sdk/current${CRAFT_CMAKE_ARGS:+:$CRAFT_CMAKE_ARGS} qtkeychain: after: - kde-neon source: https://github.com/frankosterfeld/qtkeychain.git source-tag: v0.14.0 source-depth: 0 plugin: cmake build-packages: - libsecret-1-dev stage-packages: - libsecret-1-0 - gnome-keyring cmake-parameters: - "-DKDE_INSTALL_USE_QT_SYS_PATHS=FALSE" - "-DCMAKE_INSTALL_PREFIX=/usr" - "-DCMAKE_BUILD_TYPE=RelWithDebInfo" - "-DENABLE_TESTING=OFF" - "-DBUILD_TESTING=OFF" - "-DKDE_SKIP_TEST_SETTINGS=ON" - "-DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\;/snap/kf5-5-111-qt-5-15-11-core22/current" - "-DBUILD_TRANSLATIONS=OFF" - "-DLIBSECRET_SUPPORT=ON" - "-DKEYCHAIN_DBUS=1" prime: - "-usr/include/qt5keychain" - "-usr/lib/$CRAFT_ARCH_TRIPLET/libqt5keychain.so" - "-usr/mkspecs" - "-usr/lib/$CRAFT_ARCH_TRIPLET/cmake" libmatrixclient: after: - kde-neon - qtkeychain source: https://github.com/quotient-im/libQuotient.git source-tag: 0.8.1.2 source-depth: 0 plugin: cmake build-packages: - qtmultimedia5-dev - libolm-dev - libssl-dev cmake-parameters: - "-DCMAKE_INSTALL_PREFIX=/usr" - "-DCMAKE_BUILD_TYPE=RelWithDebInfo" - "-DENABLE_TESTING=OFF" - "-DBUILD_TESTING=OFF" - "-DKDE_SKIP_TEST_SETTINGS=ON" - "-DQuotient_ENABLE_E2EE=ON" - "-DBUILDING_SHARED_QUOTIENT=ON" - "-DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\;/snap/kf5-5-111-qt-5-15-11-core22/current" neochat: after: - kde-neon - qtkeychain - libmatrixclient parse-info: - usr/share/metainfo/org.kde.neochat.appdata.xml source: . source-type: local plugin: cmake build-packages: - cmark - gcc-10 - g++-10 - libcmark-dev - kquickimageeditor-dev - libkf5qqc2desktopstyle-dev - qcoro-qt5-dev - kirigami-addons-dev - reuse - libkf5doctools-dev - qtbase5-private-dev - qml-module-org-kde-kquickimageeditor - qml-module-org-kde-qqc2desktopstyle - kirigami-addons-data - qml-module-org-kde-kirigamiaddons - qml-module-org-kde-quickcharts - libsqlite3-dev - libolm-dev stage-packages: - libcmark0.30.2 - qml-module-org-kde-kquickimageeditor - qml-module-org-kde-qqc2desktopstyle - kirigami-addons-data - qml-module-org-kde-kirigamiaddons - qml-module-org-kde-quickcharts - qml-module-org-kde-kirigami2 - reuse - libsqlite3-0 - libolm3 cmake-parameters: - "-DKDE_INSTALL_USE_QT_SYS_PATHS=FALSE" - "-DCMAKE_INSTALL_PREFIX=/usr" - "-DCMAKE_BUILD_TYPE=Release" - "-DENABLE_TESTING=OFF" - "-DBUILD_TESTING=OFF" - "-DKDE_SKIP_TEST_SETTINGS=ON" - "-DNEOCHAT_FLATPAK=ON" - "-DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\;/snap/kf5-5-111-qt-5-15-11-core22-sdk/current" - "-DKDE_INSTALL_PLUGINDIR=/usr/lib/$CRAFT_ARCH_TRIPLET/qt5/plugins/" prime: - "-usr/lib/*/cmake/*" - "-usr/include/*" - "-usr/share/ECM/*" - "-usr/share/doc/*" - "-usr/share/man/*" - "-usr/share/icons/breeze-dark*" - "-usr/bin/X11" - "-usr/lib/gcc/$CRAFT_ARCH_TRIPLET/6.0.0" - "-usr/lib/aspell/*" - "-usr/share/lintian" build-environment: &id005 - *id001 - *id002 - *id003 - *id004 cleanup: after: - kde-neon - neochat plugin: nil override-prime: | set -eux # find $CRAFT_PRIME/usr/share/doc/ -type f -not -name 'copyright' -delete # find $CRAFT_PRIME/usr/share -type d -empty -delete | /bin/true # # Unused libraries found by linter