megacoffee.net Gentoo overlay - legacy mirror
We have moved to Git. This repository is only provided for compatibility with old installations. Learn how to migrate your installation here.
changeset 233:91da5dddbae5
[sync] imported 53e3045..95f1c05 from upstream
commit 95f1c0584d79b34f950d693af51f1c1cadbd56fd
Author: Daniel Neugebauer <dneuge@energiequant.de>
Date: Sat Aug 8 14:14:24 2020 +0200
media-video/blackmagic-media-express: version bump to 3.6.1
commit 78a67d8a76ef3dbd1c80ba77c7f1b20ca5742056
Author: Daniel Neugebauer <dneuge@energiequant.de>
Date: Sat Aug 8 14:08:57 2020 +0200
media-libs/blackmagic-desktop-video-11.6: restrict splitdebug to avoid collisions with media-video/blackmagic-media-express
commit 089d46ce782c21b8de6b90ec3f913809a9020f89
Author: Daniel Neugebauer <dneuge@energiequant.de>
Date: Sat Aug 8 13:55:52 2020 +0200
media-libs/blackmagic-desktop-video: version bump to 11.6
author | Migration Sync <gentoo-overlay@megacoffee.net> |
---|---|
date | Sat, 08 Aug 2020 12:15:02 +0000 |
parents | 3c0316b4ca58 |
children | c56b9e2d29d6 |
files | media-libs/blackmagic-desktop-video/Manifest media-libs/blackmagic-desktop-video/blackmagic-desktop-video-11.6.ebuild media-video/blackmagic-media-express/Manifest media-video/blackmagic-media-express/blackmagic-media-express-3.6.1.ebuild |
diffstat | 4 files changed, 377 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/media-libs/blackmagic-desktop-video/Manifest Sat Aug 08 11:15:02 2020 +0000 +++ b/media-libs/blackmagic-desktop-video/Manifest Sat Aug 08 12:15:02 2020 +0000 @@ -1,6 +1,8 @@ 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 +DIST Blackmagic_Desktop_Video_Linux_11.6.tar.gz 1023654782 BLAKE2B 53d590e833a6bb161408b80412ae4ec213230c5ca61633e6d1ce8cda32ece93df9170b93edabcd7127a79e334f8c2915cfebac8af18f3518984f7d2ce5bc6ae2 SHA512 60b6e3b18d277e98ac72632cb0f192b559a1d825fe021f92910df2454defb838c3f69e2b1a65a02f391c0341d67d25d908f51435c6611cf497724d8d3f04f600 EBUILD blackmagic-desktop-video-10.9.ebuild 11423 BLAKE2B e9943351e04a596fc44ef48d9e3c672315ebc7f9e805f0ce68607deae8a1e961c74d67ab126a4022f124067dbfa1c80a960b9635289c5594536e65d7862b61fe SHA512 35d1b2dd5b485529593d97f779504b59d9f88cfa4c0195d43f10d8c39f45a7fe840d6924268ab87c5a879fb4f730a97accb64947a318081df2df0e9ea65a1418 EBUILD blackmagic-desktop-video-11.4.ebuild 11837 BLAKE2B 045efa51e4bd0a1cdcb049eb334c5889e15daf56210bf32c662e06d62e5f725ef6e5f2e37bf183c6473f8c7e640100b9c3d3486fca211f25a86ef1aa7e0bf61d SHA512 7f060d415e0d145f9f6eb995b83daed11a35ad5346bbdc289ef3aa2364a9edc264c4ac5b0a5dabe3035fa6ff20fcf2ad2eb8b09325f7fc0b58c3df8d1276ea61 +EBUILD blackmagic-desktop-video-11.6.ebuild 11635 BLAKE2B bb60da562a4ecc75772a082618d2387dfab140e0d6eb190da800e9eba29a0729d8d1478b82240a9889a40b41d9bd5de1a063be8f2a49a82e7ec76c7bd407a690 SHA512 2de6a7f7473143a09a4bf97795cd37967c1168b985b6454d71847949d7f4f84de22d6cb84beb8dc6f6d5040631a57a2842770dd79e20b10ea45665df2eabd308 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.6.ebuild Sat Aug 08 12:15:02 2020 +0000 @@ -0,0 +1,260 @@ +# Copyright 1999-2020 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +# TODOs: +# - fix QA notice about installing symlinks in /usr/lib + +EAPI=6 + +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.6" +DESKTOP_VIDEO_VERSION="11.6a26" +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 splitdebug" + +# 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 + sys-libs/libcxx + sys-libs/libcxxabi + " + +# 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 your DISTDIR" + einfo "(/var/cache/distfiles or /usr/portage/distfiles unless you changed it)." + 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... + symlinks=( + 'etc/init.d/DesktopVideoHelper' + 'usr/bin/BlackmagicDesktopVideoSetup' + 'usr/bin/DesktopVideoUpdateTool' + 'usr/bin/DesktopVideoUpdater' + 'usr/lib/blackmagic' + 'usr/lib/libDeckLinkAPI.so' + 'usr/lib/libDeckLinkPreviewAPI.so' + 'usr/share/applications/BlackmagicDesktopVideoSetup.desktop' + 'usr/share/applications/DesktopVideoUpdater.desktop' + 'usr/share/doc/desktopvideo' + 'usr/share/doc/desktopvideo-gui' + 'usr/share/icons/hicolor/16x16/apps/BlackmagicDesktopVideoSetup.png' + 'usr/share/icons/hicolor/16x16/apps/DesktopVideoUpdater.png' + 'usr/share/icons/hicolor/32x32/apps/BlackmagicDesktopVideoSetup.png' + 'usr/share/icons/hicolor/32x32/apps/DesktopVideoUpdater.png' + 'usr/share/icons/hicolor/48x48/apps/BlackmagicDesktopVideoSetup.png' + 'usr/share/icons/hicolor/48x48/apps/DesktopVideoUpdater.png' + 'usr/share/icons/hicolor/128x128/apps/BlackmagicDesktopVideoSetup.png' + 'usr/share/icons/hicolor/128x128/apps/DesktopVideoUpdater.png' + 'usr/share/icons/hicolor/256x256/apps/BlackmagicDesktopVideoSetup.png' + 'usr/share/icons/hicolor/256x256/apps/DesktopVideoUpdater.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/DesktopVideoHelper.1 + doman usr/share/man/man1/DesktopVideoUpdateTool.1 + doman usr/share/man/man1/DesktopVideoUpdater.1 + + # udev rules should be placed in /lib/udev/rules.d instead + 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/DesktopVideoUpdaterAutoStart.desktop /etc/xdg/autostart/DesktopVideoUpdaterAutoStart.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 DesktopVideoUpdateTool (CLI), DesktopVideoUpdater (GUI) 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 DesktopVideoUpdateTool (CLI) or, if you prefer," + einfo " DesktopVideoUpdater (GUI)" + 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 Sat Aug 08 11:15:02 2020 +0000 +++ b/media-video/blackmagic-media-express/Manifest Sat Aug 08 12:15:02 2020 +0000 @@ -1,4 +1,6 @@ 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 +DIST Blackmagic_Desktop_Video_Linux_11.6.tar.gz 1023654782 BLAKE2B 53d590e833a6bb161408b80412ae4ec213230c5ca61633e6d1ce8cda32ece93df9170b93edabcd7127a79e334f8c2915cfebac8af18f3518984f7d2ce5bc6ae2 SHA512 60b6e3b18d277e98ac72632cb0f192b559a1d825fe021f92910df2454defb838c3f69e2b1a65a02f391c0341d67d25d908f51435c6611cf497724d8d3f04f600 EBUILD blackmagic-media-express-3.5.3.ebuild 3916 BLAKE2B a0bf94856250e71031d1dbbce425659a2821a7dd8f1a308cff3ec22207d9f8733ea5be140a55cd62e3843cedfc8b7f939b746554f5bbc103f6e010c84530bfdb SHA512 619b68f564bfa61089bfe0c9a7563b22971a6e785fbf2c66627134713cbc54a8cc624b5523a2c2a51f9099694fad4a2a33ed01542f7ad07ff7413b5fbb9946a4 +EBUILD blackmagic-media-express-3.6.1.ebuild 4017 BLAKE2B e5b2deb79e661c3a5e425097b108be1415bd3bde906033e3b621ec552438984dee716f26370f6ff26f6aed0cc8043a2371a4cbd40bb7439bfadfd8ddcbcc8943 SHA512 57c1224c37d7bf6e870f1af91e2202c724fda54c80d67af047a361e22e1f7a5c4e94633c911e65e05565c37d63b4532046f5a87e6cd902250e37dbe9ca61cada EBUILD blackmagic-media-express-3.6.ebuild 4004 BLAKE2B c5ad229fc34bc323ff34ead2d4689c4d2a89a8577e77b7152584e36c629942ef4c7189e6d872556aa3b5059bdaf027f31de52f344a64450db916bfcb91d74d11 SHA512 23c0486dcc956ce4896c28e572fb1767cdd48f3496bf9f709c0ca234849ade21b4a2925dad4b8c05bd374f3cfe38e9d65ded3d599aa69b6d3c24cd57900bd287
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/media-video/blackmagic-media-express/blackmagic-media-express-3.6.1.ebuild Sat Aug 08 12:15:02 2020 +0000 @@ -0,0 +1,113 @@ +# Copyright 1999-2020 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +# TODOs: +# - fix QA notice about installing symlinks in /usr/lib + +EAPI=6 + +DESKTOP_VIDEO_SHORT_VERSION="11.6" +DESKTOP_VIDEO_VERSION="11.6a26" +MEDIA_EXPRESS_VERSION="3.6.1a24" + +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 splitdebug" + +# 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.6 + + 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() { + # 1 2 3 4 5 6 7 + # 123456789012345678901234567890123456789012345678901234567890123456789012 + 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 your DISTDIR" + einfo "(/var/cache/distfiles or /usr/portage/distfiles unless you changed it)." + 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" +}