[neon/snap-packaging/elisa-snap] /: Snapcraft: fix alsa, fix qtmultimedia.
Scarlett Moore
null at kde.org
Fri Jun 14 20:20:54 BST 2024
Git commit fc900ef8106684b481376f48c3eaf3630bf46e14 by Scarlett Moore.
Committed on 14/06/2024 at 19:20.
Pushed by scarlettmoore into branch 'master'.
Snapcraft: fix alsa, fix qtmultimedia.
M +45 -15 snapcraft.yaml
https://invent.kde.org/neon/snap-packaging/elisa-snap/-/commit/fc900ef8106684b481376f48c3eaf3630bf46e14
diff --git a/snapcraft.yaml b/snapcraft.yaml
index aa16a8a..3faaf49 100644
--- a/snapcraft.yaml
+++ b/snapcraft.yaml
@@ -18,28 +18,30 @@ apps:
plugs:
- home
- removable-media
- - mpris
- alsa
+ - mpris
command-chain:
- snap/command-chain/desktop-launch6
environment:
- LD_LIBRARY_PATH: "/snap/kf6-core22/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:/snap/kde-qt6-core22-sdk/current/usr/lib:$SNAP/usr/lib:$SNAP/lib/:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/elisa:/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:/usr/lib:/lib"
- GST_PLUGIN_PATH: "$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET/gstreamer-1.0"
- GST_PLUGIN_SYSTEM_PATH: "$SNAP/kf6/usr/lib/$CRAFT_ARCH_TRIPLET/gstreamer-1.0"
- GST_PLUGIN_SCANNER: "$SNAP/kf6/usr/lib/$CRAFT_ARCH_TRIPLET/gstreamer1.0/gstreamer-1.0/gst-plugin-scanner"
+ LD_LIBRARY_PATH: "/snap/kf6-core22/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:/snap/kde-qt6-core22-sdk/current/usr/lib:$SNAP/usr/lib:$SNAP/lib/:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/elisa:/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR:$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/pulseaudio:/usr/lib:/lib"
+ GST_PLUGIN_PATH: "$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/gstreamer-1.0"
+ GST_PLUGIN_SYSTEM_PATH: "$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/gstreamer-1.0"
+ GST_PLUGIN_SCANNER: "$SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/gstreamer1.0/gstreamer-1.0/gst-plugin-scanner"
+ ALSA_CONFIG_PATH: "$SNAP/etc/asound.conf"
+ QT_MEDIA_BACKEND: "ffmpeg"
+ QT_PLUGIN_PATH: /snap/kf6-core22/current/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/qt6/plugins
+layout:
+ /usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/alsa-lib:
+ bind: $SNAP/usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/alsa-lib
slots:
session-dbus-interface:
interface: dbus
name: org.kde.elisa
bus: session
-layout:
- /usr/lib/$CRAFT_ARCH_TRIPLET/alsa-lib:
- symlink: $SNAP/usr/lib/$CRAFT_ARCH_TRIPLET/alsa-lib
- /usr/share/alsa:
- symlink: $SNAP/usr/share/alsa
- "/etc/alsa/conf.d":
- bind: "$SNAP/etc/alsa/conf.d"
-
+ mpris-elisa:
+ interface: dbus
+ name: org.mpris.MediaPlayer2.elisa
+ bus: session
package-repositories:
- type: apt
components:
@@ -57,14 +59,22 @@ parts:
build-packages:
- libvlc-dev
- libpulse0
+ build-snaps:
+ - ffmpeg-2204-sdk
stage-packages:
+ - libasound2
+ - libasound2-plugins
+ - libasound2-data
- gstreamer1.0-alsa
- gstreamer1.0-libav
- gstreamer1.0-plugins-ugly
- gstreamer1.0-plugins-good
- gstreamer1.0-plugins-base
- gstreamer1.0-plugins-bad
+ - gstreamer1.0-tools
- libpulse0
+ stage-snaps:
+ - ffmpeg-2204
source: https://invent.kde.org/multimedia/elisa.git
source-branch: release/24.05
cmake-parameters:
@@ -84,7 +94,7 @@ parts:
- -DCMAKE_INSTALL_LIBDIR=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
- --log-level=STATUS
- -DCMAKE_LIBRARY_PATH=lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR
- - "DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\;/snap/kde-qt6-core22-sdk/current\\;/snap/kf6-core22-sdk/current/usr"
+ - "-DCMAKE_FIND_ROOT_PATH=$CRAFT_STAGE\\;/snap/kde-qt6-core22-sdk/current\\;/snap/kf6-core22-sdk/current/usr"
- "-DCMAKE_PREFIX_PATH=$CRAFT_STAGE\\;/snap/kde-qt6-core22-sdk/current\\;/snap/kf6-core22-sdk/current/usr"
build-environment:
- PATH: /snap/kde-qt6-core22-sdk/current/usr/bin${PATH:+:$PATH}
@@ -101,11 +111,31 @@ parts:
- -usr/bin/X11
- -usr/lib/gcc/$SNAPCRAFT_ARCH_TRIPLET/6.0.0
- -usr/lib/aspell/*
- - "-usr/share/lintian"
+ - -usr/share/lintian
override-build: |
craftctl default
sed -i "${CRAFT_PART_INSTALL}/usr/share/applications/org.kde.elisa.desktop" -e 's|Icon=elisa$|Icon=${SNAP}/usr/share/icons/hicolor/scalable/apps/elisa.svg|'
+ alsa-pulseaudio:
+ plugin: dump
+ source: .
+ override-pull: |
+ mkdir etc -p
+ cat > etc/asound.conf <<EOF
+ pcm.!default {
+ type pulse
+ fallback "sysdefault"
+ hint {
+ show on
+ description "Default ALSA Output (currently PulseAudio Sound Server)"
+ }
+ }
+ ctl.!default {
+ type pulse
+ fallback "sysdefault"
+ }
+ EOF
+
cleanup:
after:
- elisa
More information about the Neon-commits
mailing list