[SCM] snd/master: Use update-alternatives to map 'snd' to the right flavoured binaries

umlaeute at users.alioth.debian.org umlaeute at users.alioth.debian.org
Tue Jan 26 20:30:22 UTC 2016


The following commit has been merged in the master branch:
commit ee789a2d29fe6fa68ee0c2e319027d5f2f5ae120
Author: IOhannes m zmölnig <zmoelnig at umlautQ.umlaeute.mur.at>
Date:   Mon Jan 25 23:02:31 2016 +0100

    Use update-alternatives to map 'snd' to the right flavoured binaries

diff --git a/debian/snd-gtk-jack.postinst b/debian/snd-gtk-jack.postinst
new file mode 100644
index 0000000..a538f02
--- /dev/null
+++ b/debian/snd-gtk-jack.postinst
@@ -0,0 +1,14 @@
+#! /bin/sh
+
+set -e
+
+#DEBHELPER#
+
+FLAVOR=".gtk-jack"
+PRIORITY=50
+
+update-alternatives --install /usr/bin/snd snd /usr/bin/snd${FLAVOR} ${PRIORITY}  \
+        --slave /usr/share/man/man1/snd.1.gz snd.1.gz /usr/share/man/man1/snd${FLAVOR}.1.gz
+
+exit 0
+
diff --git a/debian/snd-gtk-jack.prerm b/debian/snd-gtk-jack.prerm
new file mode 100644
index 0000000..1e0e145
--- /dev/null
+++ b/debian/snd-gtk-jack.prerm
@@ -0,0 +1,25 @@
+#!/bin/sh -e
+
+set -e 
+
+#DEBHELPER#
+
+FLAVOR=".gtk-jack"
+
+case "$1" in
+    (remove|deconfigure)
+        update-alternatives --remove snd /usr/bin/snd${FLAVOR}
+    ;;
+    (upgrade)
+    ;;
+
+    (failed-upgrade)
+    ;;
+
+    (*)
+        echo "prerm called with unknown argument \`$1'" >&2
+        exit 0
+    ;;
+esac
+
+exit 0
diff --git a/debian/snd-gtk-pulse.postinst b/debian/snd-gtk-pulse.postinst
new file mode 100644
index 0000000..dd218c0
--- /dev/null
+++ b/debian/snd-gtk-pulse.postinst
@@ -0,0 +1,14 @@
+#! /bin/sh
+
+set -e
+
+#DEBHELPER#
+
+FLAVOR=".gtk-pulse"
+PRIORITY=40
+
+update-alternatives --install /usr/bin/snd snd /usr/bin/snd${FLAVOR} ${PRIORITY}  \
+        --slave /usr/share/man/man1/snd.1.gz snd.1.gz /usr/share/man/man1/snd${FLAVOR}.1.gz
+
+exit 0
+
diff --git a/debian/snd-gtk-pulse.prerm b/debian/snd-gtk-pulse.prerm
new file mode 100644
index 0000000..309635e
--- /dev/null
+++ b/debian/snd-gtk-pulse.prerm
@@ -0,0 +1,25 @@
+#!/bin/sh -e
+
+set -e 
+
+#DEBHELPER#
+
+FLAVOR=".gtk-pulse"
+
+case "$1" in
+    (remove|deconfigure)
+        update-alternatives --remove snd /usr/bin/snd${FLAVOR}
+    ;;
+    (upgrade)
+    ;;
+
+    (failed-upgrade)
+    ;;
+
+    (*)
+        echo "prerm called with unknown argument \`$1'" >&2
+        exit 0
+    ;;
+esac
+
+exit 0
diff --git a/debian/snd-nox.postinst b/debian/snd-nox.postinst
new file mode 100644
index 0000000..6675a97
--- /dev/null
+++ b/debian/snd-nox.postinst
@@ -0,0 +1,14 @@
+#! /bin/sh
+
+set -e
+
+#DEBHELPER#
+
+FLAVOR=".nox"
+PRIORITY=30
+
+update-alternatives --install /usr/bin/snd snd /usr/bin/snd${FLAVOR} ${PRIORITY}  \
+        --slave /usr/share/man/man1/snd.1.gz snd.1.gz /usr/share/man/man1/snd${FLAVOR}.1.gz
+
+exit 0
+
diff --git a/debian/snd-nox.prerm b/debian/snd-nox.prerm
new file mode 100644
index 0000000..715580d
--- /dev/null
+++ b/debian/snd-nox.prerm
@@ -0,0 +1,25 @@
+#!/bin/sh -e
+
+set -e 
+
+#DEBHELPER#
+
+FLAVOR=".nox"
+
+case "$1" in
+    (remove|deconfigure)
+        update-alternatives --remove snd /usr/bin/snd${FLAVOR}
+    ;;
+    (upgrade)
+    ;;
+
+    (failed-upgrade)
+    ;;
+
+    (*)
+        echo "prerm called with unknown argument \`$1'" >&2
+        exit 0
+    ;;
+esac
+
+exit 0

-- 
snd packaging



More information about the pkg-multimedia-commits mailing list