We have moved to Git. This repository is only provided for compatibility with old installations. Learn how to migrate your installation here.

changeset 224:c80972b7e7e2

Blackmagic Desktop Video and Media Express updated to latest version
author Daniel Neugebauer <dneuge@energiequant.de>
date Mon, 10 Feb 2020 14:22:31 +0100
parents ea74cb722388
children 7420d1ddb268
files media-libs/blackmagic-desktop-video/Manifest media-libs/blackmagic-desktop-video/blackmagic-desktop-video-11.4.ebuild media-video/blackmagic-media-express/Manifest media-video/blackmagic-media-express/blackmagic-media-express-3.6.ebuild
diffstat 4 files changed, 373 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/media-libs/blackmagic-desktop-video/Manifest	Mon Feb 10 12:40:54 2020 +0100
+++ b/media-libs/blackmagic-desktop-video/Manifest	Mon Feb 10 14:22:31 2020 +0100
@@ -1,4 +1,6 @@
 AUX 10_9_0__4_10_get_user_pages_remote.patch 2289 BLAKE2B 44256aee282abfcefa884e91168f0e64e13d7dc6b324027fdd9c98104673daa026b6adca83fd511ac04c45986be60aaf633c8dc7b1babd20cdae23b616d6ebda SHA512 be99305d69925d53deb6a80bdf91d19832ecec28a72c0f838d3bde87727578d5da54d0e2001f6d3961d1bb546e3b59c694894425a4ff2063da8340e3514abd2b
 DIST Blackmagic_Desktop_Video_Linux_10.9.tar.gz 662892811 BLAKE2B ccbd85b53add4a93db358af666335171776dc7457c46db4e2d715a595f1aaceb5a62fa95695fee7c3c6b344153b405f5d88e6c4c89297352a65687079acd4710 SHA512 d73da849b6cd1cf72f3ff75500da04b34b12c94bd1baa0cdf31674a91539231c4b3da914cad4069fbb1fe24450a877cd90fc34aa2f5f05606d3ef2eeef4ac96f
+DIST Blackmagic_Desktop_Video_Linux_11.4.tar.gz 981137442 BLAKE2B 5be5bb2fd6e3e38447c3a9fb2881fa4752d53999ca3124ea6227c8b716b8c45f8d81def94ee7bf62b881fa6d2b70eedb5aedb63a1486a15486a7c98e598890bb SHA512 cab68727387e528b066ad9b55c0363b1d3d9b59540406579d3499b451343f3119d55ef21c5a10cbffea7c73f22c3a3dda66b11381769555709db543fa4584ada
 EBUILD blackmagic-desktop-video-10.9.ebuild 11340 BLAKE2B 79078ddd563bfb29f6bbcf2130c845c4ee7469e1e22c8dce65974fb8d1dee1ef507933af9cc3a5e7a86f9f98d17f94e275e698a0dce31994d05bf79eab01e7c7 SHA512 58aa85895d132c2eb3a01043d432e0b205b1f3981e93ff34f4243010fd4db66a1b052618ab66160787749314ee161d60e471b20754c678d544ab56f30a8f9ef8
+EBUILD blackmagic-desktop-video-11.4.ebuild 11754 BLAKE2B d8ee249351f0d6e0a8ec22a91aca08f639e1d4300f1514b62d994d22216337164fad714caf831269800dae521a0e231e859ff0826ab4ece982cc4485f6b5ad8e SHA512 7eb596a0911c5ffb9df4f3f14ec8a95ac5069c58153cab315460140ad8439a49dec5e3c48f9d727445204defd2aa64ee86684b82ac922e1c801d6590a03ac4d4
 MISC metadata.xml 430 BLAKE2B 42d8b88622052da978feec46f1a1c9f9f377151ae1016ae724d2e7f1f96711f15b5adb3ed2c39a729ad6a11750627a46b8621c502654c99048e11e6d0f0fc3cd SHA512 076c508775866e0edc461580e346d8e83dd60540eb0428cf830e39a02415843984900783b0edde23a9047697f13b4d93f856738839e0dd3516dd751134e8da0d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/media-libs/blackmagic-desktop-video/blackmagic-desktop-video-11.4.ebuild	Mon Feb 10 14:22:31 2020 +0100
@@ -0,0 +1,259 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+# TODOs:
+#  - fix QA notice about installing symlinks in /usr/lib
+
+EAPI=5
+
+inherit linux-mod
+
+DESCRIPTION="Desktop Video - drivers and tools for products by Blackmagic Design including DeckLink and Intensity"
+HOMEPAGE="http://www.blackmagicdesign.com/"
+HOMEPAGE_DOWNLOAD_NAME="Desktop Video ${PV}"
+
+SRC_URI="Blackmagic_Desktop_Video_Linux_${PV}.tar.gz"
+DESKTOP_VIDEO_SHORT_VERSION="11.4"
+DESKTOP_VIDEO_VERSION="11.4a14"
+CONTAINER_DIR="Blackmagic_Desktop_Video_Linux_${DESKTOP_VIDEO_SHORT_VERSION}"
+UNPACKED_DIR="desktopvideo-${DESKTOP_VIDEO_VERSION}-x86_64"
+
+LICENSE="BlackmagicDesktopVideo"
+SLOT="0"
+KEYWORDS="~amd64"
+#IUSE="autostart patch_compat"
+IUSE="autostart"
+RESTRICT="fetch"
+
+# dependencies found via command: (ldd would include transitive dependencies)
+# equery belongs $(for file in /usr/lib/libDeckLink* /usr/lib/blackmagic/*; do objdump -p $file | grep NEEDED; done 2>/dev/null | cut -b24- | sort | uniq | grep -vE 'lib(Qt5(Core|Network|Gui|Widgets)|qxcb|qgtk2|DeckLink)')
+DEPEND=""
+RDEPEND="${DEPEND}
+	 media-libs/mesa
+	 sys-devel/gcc
+	 sys-libs/glibc
+	"
+
+# supress QA warnings about stripping etc., i.e. stuff we cannot change since we install prebuilt binaries
+QA_PREBUILT="opt/blackmagic-desktop-video/usr/bin/* opt/blackmagic-desktop-video/usr/lib/*"
+
+# for kernel module compilation
+MODULE_NAMES="blackmagic(misc:${S}/usr/src/blackmagic-${DESKTOP_VIDEO_VERSION}:${S}/usr/src/blackmagic-${DESKTOP_VIDEO_VERSION}) blackmagic-io(misc:${S}/usr/src/blackmagic-io-${DESKTOP_VIDEO_VERSION}:${S}/usr/src/blackmagic-io-${DESKTOP_VIDEO_VERSION})"
+BUILD_TARGETS="clean all"
+
+#PATCH_COMPAT_MAX_MAJOR=4
+#PATCH_COMPAT_MAX_MINOR=10
+
+#OFFICIAL_COMPAT_MAX_MAJOR=4
+#OFFICIAL_COMPAT_MAX_MINOR=9
+
+pkg_nofetch() {
+	#               1         2         3         4         5         6         7         8
+	#      1234567890123456789012345678901234567890123456789012345678901234567890123456789012
+	einfo "Please visit ${HOMEPAGE} and download \"${HOMEPAGE_DOWNLOAD_NAME}\""
+	einfo "for your product from the support section and move it to ${DISTDIR}"
+	einfo ""
+	einfo "  expected filename: ${SRC_URI}"
+	einfo ""
+	einfo "If your browser downloads a .tar file you will need to rename it to .tar.gz"
+}
+
+#pkg_pretend() {
+#	if kernel_is -gt $PATCH_COMPAT_MAX_MAJOR $PATCH_COMPAT_MAX_MINOR; then
+#		#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+#		ewarn "Your kernel version seems to be unsupported; you have two options if modules do"
+#		ewarn "not work/compile:"
+#		ewarn ""
+#		ewarn " 1) Recommended: downgrade to an officially supported kernel version (e.g. ${OFFICIAL_COMPAT_MAX_MAJOR}.${OFFICIAL_COMPAT_MAX_MINOR})"
+#		ewarn ""
+#		ewarn " 2) Downgrade to an inofficially supported kernel version (max. ${PATCH_COMPAT_MAX_MAJOR}.${PATCH_COMPAT_MAX_MINOR}) and apply"
+#		ewarn "    the *inofficial* patch which allows more recent kernel versions but may void"
+#		ewarn "    warranty permanently. This can be done by setting the USE-flag patch_compat"
+#		ewarn "    for this ebuild. The patch is not guaranteed to work at all and may even"
+#		ewarn "    damage your hardware. Use at your own risk; you've been warned!"
+#		ewarn ""
+#		ewarn "It's highly recommended to choose option 1 and wait for an officially supported"
+#		ewarn "update unless you want to risk loosing your hardware and support."
+#	elif kernel_is -gt $OFFICIAL_COMPAT_MAX_MAJOR $OFFICIAL_COMPAT_MAX_MINOR && ! use patch_compat; then
+#		#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+#		ewarn "Your kernel version seems to be unsupported; you have two options if modules do"
+#		ewarn "not work/compile:"
+#		ewarn ""
+#		ewarn " 1) Recommended: downgrade to an officially supported kernel version (e.g. ${OFFICIAL_COMPAT_MAX_MAJOR}.${OFFICIAL_COMPAT_MAX_MINOR})"
+#		ewarn ""
+#		ewarn " 2) Apply an *inofficial* patch which allows more recent kernel versions but may"
+#		ewarn "    void warranty permanently. This can be done by setting the USE-flag"
+#		ewarn "    patch_compat for this ebuild. The patch is not guaranteed to work at all"
+#		ewarn "    and may even damage your hardware. Use at your own risk; you've been warned!"
+#		ewarn ""
+#		ewarn "It's highly recommended to choose option 1 and wait for an officially supported"
+#		ewarn "update unless you want to risk loosing your hardware and support."
+#	elif kernel_is -le $OFFICIAL_COMPAT_MAX_MAJOR $OFFICIAL_COMPAT_MAX_MINOR && use patch_compat; then
+#		#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+#		einfo "Your kernel version is officially supported by this release. It is recommended"
+#		einfo "to unset patch_compat USE flag until you need it again."
+#		einfo "Inofficial patches will not be applied this time."
+#	fi
+#}
+
+src_unpack() {
+	unpack ${A}
+	
+	cd ${WORKDIR}
+	tar xfz ${CONTAINER_DIR}/other/x86_64/desktopvideo-${DESKTOP_VIDEO_VERSION}-x86_64.tar.gz
+	
+	# symlink to what is supposed to have been prepared
+	ln -s ${UNPACKED_DIR} ${P}
+}
+
+#src_prepare() {
+#	if kernel_is -gt $OFFICIAL_COMPAT_MAX_MAJOR $OFFICIAL_COMPAT_MAX_MINOR && use patch_compat; then
+#		if kernel_is -gt 4 9; then
+#			epatch "${FILESDIR}/10_9_0__4_10_get_user_pages_remote.patch"
+#		fi
+#	fi
+#}
+
+src_compile() {
+	# library/tools are binary but kernel module requires compilation
+	linux-mod_src_compile
+}
+
+src_install() {
+	# all pre-built binaries should go into /opt and be symlinked to usr/bin etc.
+	finalinstalldir="/opt/blackmagic-desktop-video"
+	installdir="${D}${finalinstalldir}"
+	
+	mkdir -p ${installdir}
+	cp -a ${WORKDIR}/${UNPACKED_DIR}/* ${installdir}/
+	
+	# copy text files (readme and license) from parent directory
+	cp -a ${WORKDIR}/${CONTAINER_DIR}/*.txt ${installdir}/
+	
+	# there should a blank directory in /etc according to the archive...
+	mkdir -p ${installdir}/etc/blackmagic
+	chmod 755 ${installdir}/etc/blackmagic
+	
+	# NOTE: Not linking usr/lib/systemd as I don't use that and thus can't test it...
+	# Also omitting DesktopVideoUpdater as it is useless when installed from ebuilds.
+	symlinks=(
+			'etc/init.d/DesktopVideoHelper'
+			'usr/bin/BlackmagicDesktopVideoSetup'
+			'usr/bin/BlackmagicFirmwareUpdater'
+			'usr/bin/BlackmagicFirmwareUpdaterGui'
+			'usr/lib/blackmagic'
+			'usr/lib/libDeckLinkAPI.so'
+			'usr/lib/libDeckLinkPreviewAPI.so'
+			'usr/lib/libScannerAPI.so'
+			'usr/share/applications/BlackmagicDesktopVideoSetup.desktop'
+			'usr/share/applications/BlackmagicFirmwareUpdaterGui.desktop'
+			'usr/share/doc/desktopvideo'
+			'usr/share/doc/desktopvideo-gui'
+			'usr/share/doc/desktopvideo-scanner'
+			'usr/share/icons/hicolor/16x16/apps/BlackmagicDesktopVideoSetup.png'
+			'usr/share/icons/hicolor/16x16/apps/BlackmagicFirmwareUpdaterGui.png'
+			'usr/share/icons/hicolor/32x32/apps/BlackmagicDesktopVideoSetup.png'
+			'usr/share/icons/hicolor/32x32/apps/BlackmagicFirmwareUpdaterGui.png'
+			'usr/share/icons/hicolor/48x48/apps/BlackmagicDesktopVideoSetup.png'
+			'usr/share/icons/hicolor/48x48/apps/BlackmagicFirmwareUpdaterGui.png'
+			'usr/share/icons/hicolor/128x128/apps/BlackmagicDesktopVideoSetup.png'
+			'usr/share/icons/hicolor/128x128/apps/BlackmagicFirmwareUpdaterGui.png'
+			'usr/share/icons/hicolor/256x256/apps/BlackmagicDesktopVideoSetup.png'
+			'usr/share/icons/hicolor/256x256/apps/BlackmagicFirmwareUpdaterGui.png'
+                 )
+	
+	for path in "${symlinks[@]}"; do
+		dosym /opt/blackmagic-desktop-video/${path} ${path}
+	done
+	
+	# dneuge: no clue on how to use this...
+	## QA notice says we should generate a linker script if we don't place libraries in /usr/lib
+	## see: https://devmanual.gentoo.org/eclass-reference/toolchain-funcs.eclass/index.html
+	#gen_usr_ldscript usr/lib/libDeckLinkAPI.so usr/lib/libDeckLinkPreviewAPI.so
+
+	# don't symlink man-pages, install a copy instead
+	# NOTE: DesktopVideoHelper appears to have disappeared, so we won't install the man page either
+	doman usr/share/man/man1/BlackmagicDesktopVideoSetup.1
+	doman usr/share/man/man1/BlackmagicFirmwareUpdater.1
+	doman usr/share/man/man1/BlackmagicFirmwareUpdaterGui.1
+	
+	# udev rules should be placed in /lib/udev/rules.d instead
+	dosym /opt/blackmagic-desktop-video/etc/udev/rules.d/51-cintel.rules /lib/udev/rules.d/51-cintel.rules
+	dosym /opt/blackmagic-desktop-video/etc/udev/rules.d/55-blackmagic.rules /lib/udev/rules.d/55-blackmagic.rules
+	
+	# add firmware check to autostart?
+	if use autostart; then
+		dosym /opt/blackmagic-desktop-video/etc/xdg/autostart/BlackmagicFirmwareUpdaterGuiAutoStart.desktop /etc/xdg/autostart/BlackmagicFirmwareUpdaterGuiAutoStart.desktop
+	fi
+	
+	# kernel module
+	linux-mod_src_install
+}
+
+pkg_postinst() {
+	# kernel module
+	linux-mod_pkg_postinst
+	
+	#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+	einfo ""
+	einfo "Please do *NOT* report any QA errors to Gentoo or Blackmagic!"
+	einfo ""
+	einfo "Kernel modules are blackmagic and blackmagic-io. Try blackmagic if in doubt."
+	einfo "When upgrading, please rmmod both first. Then modprobe blackmagic to see if it"
+	einfo "works (it should print your devices to kernel log)."
+	einfo ""
+	einfo "Installed tools are BlackmagicFirmwareUpdater, BlackmagicFirmwareUpdaterGui and"
+	einfo "BlackmagicDesktopVideoSetup."
+	einfo ""
+	einfo "For Media Express emerge media-video/blackmagic-media-express."
+	einfo ""
+	if use autostart; then
+		einfo "Automated firmware update check has been installed."
+	else
+		einfo "Automated firmware update check has *not* been installed this time."
+		einfo "(set USE flag autostart if you want that)"
+	fi
+	einfo ""
+	einfo "If your product is not being recognized, there are two common reasons:"
+	einfo ""
+	einfo " 1) You may need to increase the vmalloc limit in your kernel."
+	einfo "    This can be done by adding e.g. vmalloc=256M to your kernel boot line. You"
+	einfo "    can see current usage by running"
+	einfo ""
+	einfo "    # grep VmallocUsed /proc/meminfo"
+	einfo ""
+	einfo " 2) Your firmware may be outdated. Make sure you reload the modules (or simply"
+	einfo "    reboot) and then run BlackmagicFirmwareUpdater or, if you prefer,"
+	einfo "    BlackmagicFirmwareUpdaterGui"
+	einfo ""
+	einfo "Licenses can be found in: ${finalinstalldir}/usr/share/doc/"
+	einfo ""
+	einfo "We are reloading udev rules now..."
+	/bin/udevadm control --reload-rules || einfo " ... failed, you may want to check this before rebooting!"
+
+	#if kernel_is -gt $OFFICIAL_COMPAT_MAX_MAJOR $OFFICIAL_COMPAT_MAX_MINOR && use patch_compat; then
+	#	#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+	#	ewarn ""
+	#	ewarn "    *** YOU HAVE APPLIED INOFFICIAL PATCHES TO INSTALLED KERNEL MODULES ***"
+	#	ewarn "    ***    DO NOT REPORT ANY ERRORS TO BLACKMAGIC, YOU BREAK WARRANTY   ***"
+	#	ewarn ""
+	#	ewarn "Applying those patches is generally discouraged as it can potentially damage"
+	#	ewarn "your hardware and therefore may void your warranty. You are recommended to"
+	#	ewarn "go back to an older kernel and wait for an official update instead of applying"
+	#	ewarn "these patches. At the very least, note that there is no support of any kind when"
+	#	ewarn "using patched drivers. Avoid contacting the vendor for support while using"
+	#	ewarn "inofficial drivers. Revert to official drivers and retry with untainted hardware"
+	#	ewarn "if something doesn't work as expected. Additionally, your system may behave"
+	#	ewarn "unstable."
+	#	ewarn ""
+	#	ewarn "Remove USE-flag patch_compat and re-emerge this ebuild immediately before use"
+	#	ewarn "if you enabled it accidentally."
+	#	ewarn ""
+	#	ewarn "                           *** USE AT YOUR OWN RISK ***"
+	#fi
+}
+
+pkg_postrm() {
+	# kernel module
+	linux-mod_pkg_postrm
+}
--- a/media-video/blackmagic-media-express/Manifest	Mon Feb 10 12:40:54 2020 +0100
+++ b/media-video/blackmagic-media-express/Manifest	Mon Feb 10 14:22:31 2020 +0100
@@ -1,2 +1,4 @@
 DIST Blackmagic_Desktop_Video_Linux_10.9.tar.gz 662892811 BLAKE2B ccbd85b53add4a93db358af666335171776dc7457c46db4e2d715a595f1aaceb5a62fa95695fee7c3c6b344153b405f5d88e6c4c89297352a65687079acd4710 SHA512 d73da849b6cd1cf72f3ff75500da04b34b12c94bd1baa0cdf31674a91539231c4b3da914cad4069fbb1fe24450a877cd90fc34aa2f5f05606d3ef2eeef4ac96f
+DIST Blackmagic_Desktop_Video_Linux_11.4.tar.gz 981137442 BLAKE2B 5be5bb2fd6e3e38447c3a9fb2881fa4752d53999ca3124ea6227c8b716b8c45f8d81def94ee7bf62b881fa6d2b70eedb5aedb63a1486a15486a7c98e598890bb SHA512 cab68727387e528b066ad9b55c0363b1d3d9b59540406579d3499b451343f3119d55ef21c5a10cbffea7c73f22c3a3dda66b11381769555709db543fa4584ada
 EBUILD blackmagic-media-express-3.5.3.ebuild 3673 BLAKE2B 7ee35cdf2b2aac7e4cb6dc57723e38b81be61b66d6b43d906b3eb0740217dc7014d377717f5f44c34ace976794bb1b39df7b534ef580f4560bd96b45569da1a6 SHA512 93e51497b9c098c6f99e869732594b965596f84badda5204325138e6435a767af228a12ca726150dc79ea6c4502d1e359279b8a5bee0dcd13e338420d13e12e6
+EBUILD blackmagic-media-express-3.6.ebuild 3761 BLAKE2B aab6ac04a9183c95d800675b764b6b274f8bc3053b08458f6dc9d3ab40d830868472ddc9258ee567d8cba7141dd630c73cd075bc2ccc00208d0f8592c3c1669c SHA512 2f83423752d6959c1f57905f5410c3c503cbf3c55458c51f80eef9b55649cf257ef33f1b285ca6acc079268cb011b22f21724ef7710a5bfdf7c014c2325bf2c5
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/media-video/blackmagic-media-express/blackmagic-media-express-3.6.ebuild	Mon Feb 10 14:22:31 2020 +0100
@@ -0,0 +1,110 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+# TODOs:
+#  - fix QA notice about installing symlinks in /usr/lib
+
+EAPI=5
+
+DESKTOP_VIDEO_SHORT_VERSION="11.4"
+DESKTOP_VIDEO_VERSION="11.4a14"
+MEDIA_EXPRESS_VERSION="3.6a13"
+
+DESCRIPTION="Media Express - Blackmagic Design's tool for media capture, organization and playback"
+HOMEPAGE="http://www.blackmagicdesign.com/"
+HOMEPAGE_DOWNLOAD_NAME="Desktop Video ${DESKTOP_VIDEO_SHORT_VERSION}"
+
+SRC_URI="Blackmagic_Desktop_Video_Linux_${DESKTOP_VIDEO_SHORT_VERSION}.tar.gz"
+UNPACKED_DIR="mediaexpress-${MEDIA_EXPRESS_VERSION}-x86_64"
+
+LICENSE="BlackmagicDesktopVideo"
+SLOT="0"
+KEYWORDS="~amd64"
+#IUSE="autostart"
+RESTRICT="fetch"
+
+# dependencies for binaries found by commands: (ldd lists transitive dependencies as well which isn't what we want)
+# for file in /usr/lib/blackmagic/me/*; do objdump -p $file | grep NEEDED; done 2>/dev/null | cut -b24- | sort | uniq | grep -vE 'lib(Qt|MXF|DNxHDCodec)'
+# equery belongs $(for file in /usr/lib/blackmagic/me/*; do objdump -p $file | grep NEEDED; done 2>/dev/null | cut -b24- | sort | uniq | grep -vE 'lib(Qt|MXF|DNxHDCodec)')
+
+DEPEND=""
+RDEPEND="${DEPEND}
+	 >=media-libs/blackmagic-desktop-video-11.4
+
+	 dev-libs/glib:2
+	 media-libs/alsa-lib
+	 media-libs/fontconfig
+	 media-libs/freetype
+	 media-libs/mesa
+	 sys-devel/gcc
+	 sys-libs/glibc
+	 virtual/glu
+	 x11-libs/libICE
+	 x11-libs/libSM
+	 x11-libs/libX11
+	 x11-libs/libXi
+	 x11-libs/libxcb
+	"
+
+# supress QA warnings about stripping etc., i.e. stuff we cannot change since we install prebuilt binaries
+QA_PREBUILT="opt/blackmagic-media-express/usr/lib/*"
+
+pkg_nofetch() {
+	einfo "Media Express is bundled with Desktop Video downloads."
+	einfo ""
+	einfo "Please visit ${HOMEPAGE} and download \"${HOMEPAGE_DOWNLOAD_NAME}\""
+	einfo "for your product from the support section and move it to ${DISTDIR}"
+	einfo ""
+	einfo "  expected filename: ${SRC_URI}"
+	einfo ""
+	einfo "If your browser downloads a .tar file you will need to rename it to .tar.gz"
+}
+
+src_unpack() {
+	unpack ${A}
+	
+	cd ${WORKDIR}
+	tar xfz Blackmagic_Desktop_Video_Linux_${DESKTOP_VIDEO_SHORT_VERSION}/other/x86_64/mediaexpress-${MEDIA_EXPRESS_VERSION}-x86_64.tar.gz
+	
+	# symlink to what is supposed to have been prepared
+	ln -s ${UNPACKED_DIR} ${P}
+}
+
+src_install() {
+	# all pre-built binaries should go into /opt and be symlinked to usr/bin etc.
+	finalinstalldir="/opt/blackmagic-media-express"
+	installdir="${D}${finalinstalldir}"
+	
+	mkdir -p ${installdir}
+	cp -a ${WORKDIR}/${UNPACKED_DIR}/* ${installdir}/
+	
+	# NOTE: Not linking usr/lib/systemd as I don't use that and thus can't test it...
+	symlinks=(
+			'usr/bin/MediaExpress'
+			'usr/lib/blackmagic/MediaExpress'
+			'usr/share/applications/MediaExpress.desktop'
+			'usr/share/doc/mediaexpress'
+			'usr/share/icons/hicolor/32x32/apps/MediaExpress.png'
+			'usr/share/icons/hicolor/48x48/apps/MediaExpress.png'
+			'usr/share/icons/hicolor/256x256/apps/MediaExpress.png'
+                 )
+	
+	for path in "${symlinks[@]}"; do
+		dosym ${finalinstalldir}/${path} ${path}
+	done
+	
+	# dneuge: no clue on how to use this...
+	## QA notice says we should generate a linker script if we don't place libraries in /usr/lib
+	## see: https://devmanual.gentoo.org/eclass-reference/toolchain-funcs.eclass/index.html
+	#gen_usr_ldscript usr/lib/libDeckLinkAPI.so usr/lib/libDeckLinkPreviewAPI.so
+
+	# don't symlink man-pages, install a copy instead
+	doman usr/share/man/man1/*.1
+}
+
+pkg_postinst() {
+	#      12345678901234567890123456789012345678901234567890123456789012345678901234567890
+	einfo "Please do *NOT* report any QA errors to Gentoo or Blackmagic!"
+	einfo ""
+	einfo "License can be found in: ${finalinstalldir}/usr/share/doc/mediaexpress/License.txt"
+}