summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorPerry Hung2016-03-30 01:26:34 -0400
committerPerry Hung2016-03-30 01:30:31 -0400
commit98abbb9876ee45618215325e22a9afe2cf86d11f (patch)
treee99e8a144d95addaafbe13041c3121cca095bb1d
parentd1168bd47ddb02bfd0ba31212aacf750d9fbdaaf (diff)
downloadaur-98abbb9876ee45618215325e22a9afe2cf86d11f.tar.gz
fetch tarball directly from Blackmagic
Blackmagic hosts Desktop Video versions behind expiring links. Retrieve the archive through one of these temporary links and verify the checksum.
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD16
2 files changed, 14 insertions, 5 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 79554459683b..3cf891db6224 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -12,10 +12,9 @@ pkgbase = decklink
depends = libpng12
depends = glu
depends = qt4
+ makedepends = curl
options = !strip
options = staticlibs
- source = file://Blackmagic_Desktop_Video_Linux_10.6.2.tar
- sha256sums = da743c87b3af7fb50b3d17af67b75b253141896540589aa6119ecaed21979142
pkgname = decklink
diff --git a/PKGBUILD b/PKGBUILD
index 65729ba6ac30..6a2c13187e74 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,16 +9,26 @@ pkgdesc="Drivers for Blackmagic Design DeckLink, Intensity or Multibridge video
arch=('i686' 'x86_64')
url="http://www.blackmagic-design.com/products/"
license=('custom')
+makedepends=('curl')
depends=('linux-headers' 'libxml2' 'libpng12' 'glu' 'qt4')
options=('!strip' 'staticlibs')
install='decklink.install'
-source=("file://Blackmagic_Desktop_Video_Linux_${pkgver%a*}.tar")
-sha256sums=('da743c87b3af7fb50b3d17af67b75b253141896540589aa6119ecaed21979142')
-
[ "$CARCH" = "i686" ] && _arch='i386'
[ "$CARCH" = "x86_64" ] && _arch='x86_64'
+pkgsrc_url="https://www.blackmagicdesign.com/api/register/us/download/3f0844bdcfc24fd1a631aeca0d2cefe6"
+pkgsrc_file=$pkgname-${_dvver}.tar.gz
+pkgsrc_sha256sum="da743c87b3af7fb50b3d17af67b75b253141896540589aa6119ecaed21979142"
+
+prepare() {
+ temp_url=`curl --data '{country":"us","platform":"Linux"}' $pkgsrc_url`
+ curl -o $pkgsrc_file $temp_url
+ shasum=`sha256sum $pkgsrc_file | cut -d " " -f1`
+ [ "${shasum}" != "${pkgsrc_sha256sum}" ] && ( echo "Integrity check failed."; exit 1 )
+ tar xf ${pkgsrc_file}
+}
+
package() {
mkdir -p "$pkgdir/usr/share/licenses/$pkgname"
ln -s /usr/share/doc/desktopvideo/License.txt "$pkgdir/usr/share/licenses/$pkgname/COPYING"