summaryrefslogtreecommitdiffstats
path: root/config/chroot_local-hooks/59-libdvd-pkg
diff options
context:
space:
mode:
Diffstat (limited to 'config/chroot_local-hooks/59-libdvd-pkg')
-rwxr-xr-xconfig/chroot_local-hooks/59-libdvd-pkg36
1 files changed, 36 insertions, 0 deletions
diff --git a/config/chroot_local-hooks/59-libdvd-pkg b/config/chroot_local-hooks/59-libdvd-pkg
new file mode 100755
index 0000000..4c8d817
--- /dev/null
+++ b/config/chroot_local-hooks/59-libdvd-pkg
@@ -0,0 +1,36 @@
+#!/bin/sh
+set -e
+set -u
+set -x
+
+echo "Installing libdvd-pkg"
+
+apt-get --yes install libdvd-pkg
+dpkg-reconfigure libdvd-pkg
+
+# Create and install fake libdvd-pkg package
+local tmp
+tmp="$(mktemp -d)"
+apt-get install --yes equivs
+
+LIBDVD_PKG_VERSION=$(dpkg-query -s libdvd-pkg | grep Version | cut -d ' ' -f2 )
+
+cat > "${tmp}/libdvd-pkg-${LIBDVD_PKG_VERSION}.control" << EOF
+Section: multimedia
+Priority: optional
+Homepage: https://tails.boum.org/
+Standards-Version: 3.6.2
+
+Package: libdvd-pkg-${LIBDVD_PKG_VERSION}
+Maintainer: Tails developers <amnesia@boum.org>
+Provides: libdvd-pkg
+Architecture: all
+Description: (Fake) libdvd-pkg package
+ Provide placeholder to keep libdvdcss2 happy.
+EOF
+
+cd "${tmp}"
+equivs-build "${tmp}/libdvd-pkg-${LIBDVD_PKG_VERSION}.control"
+dpkg -i "${tmp}/libdvd-pkg-${LIBDVD_PKG_VERSION}_1.0_all.deb"
+cd -
+rm -R "${tmp}"