-
Notifications
You must be signed in to change notification settings - Fork 0
/
PKGBUILD
71 lines (62 loc) · 2.58 KB
/
PKGBUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#!/bin/bash
# Disable various shellcheck rules that produce false positives in this file.
# Repository rules should be added to the .shellcheckrc file located in the
# repository root directory, see https://github.com/koalaman/shellcheck/wiki
# and https://archiv8.github.io for further information.
# shellcheck disable=SC2034,SC2154
# [ToDo]: Add files: User documentation
# [ToDo]: Add files: Tooling
# [FixMe]: Namcap warnings and errors
# Maintainer: Ross Clark <archiv8@artisteducator.com>
# Contributor: Ross Clark <archiv8@artisteducator.com>
_downloadid='5d8eaacc274b409dbbee4b9d7724d073'
_referid='0be12cd3250349e4b90af2118b34b19c'
_siteurl="https://www.blackmagicdesign.com/api/register/us/download/${_downloadid}"
_useragent="User-Agent: Mozilla/5.0 (X11; Linux ${CARCH}) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.5060.134 Safari/537.36"
_reqjson="{ \
\"platform\": \"Linux\", \
\"country\": \"us\", \
\"firstname\": \"Arch\", \
\"lastname\": \"Linux\", \
\"email\": \"someone@archlinux.org\", \
\"phone\": \"202-555-0194\", \
\"state\": \"New York\", \
\"city\": \"AUR\", \
\"hasAgreedToTerms\": true, \
\"product\": \"Desktop Video ${pkgver} SDK\" \
}"
_srcurl="$(curl \
-s \
-H "$_useragent" \
-H 'Content-Type: application/json;charset=UTF-8' \
-H "Referer: https://www.blackmagicdesign.com/support/download/${_referid}/Linux" \
--data-ascii "$_reqjson" \
--compressed \
"$_siteurl")"
DLAGENTS=("https::/usr/bin/curl \
-gqb '' -C - --retry 3 --retry-delay 3 \
-H Upgrade-Insecure-Requests:\ 1 \
-H ${_useragent// /\\ } \
-o %o \
--compressed \
%u")
pkgname=decklink-sdk
pkgver=12.4
pkgrel=1
# epoch=
pkgdesc='Blackmagic DeckLink SDK'
arch=('any')
url='https://www.blackmagicdesign.com/support/family/capture-and-playback'
license=('custom')
makedepends=('poppler')
provides=('blackmagic-decklink-sdk')
conflicts=('blackmagic-decklink-sdk')
source=("Blackmagic_DeckLink_SDK_${pkgver}.zip"::"$_srcurl")
sha512sums=('ba28ede4b9618babd0ee14836f65ad746f3ff5c36115bc56628e262674fbf264c5c684947c68b60d9d611bdf01a43788e27ee8cd27dff2ee2ffd86ce1ccbc5ff')
prepare() {
pdftotext -layout "Blackmagic DeckLink SDK ${pkgver}/End User License Agreement.pdf"
}
package() {
install -D -m644 "Blackmagic DeckLink SDK ${pkgver}/End User License Agreement.txt" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
cp -dr --no-preserve='ownership' "Blackmagic DeckLink SDK ${pkgver}/Linux/include" "${pkgdir}/usr"
}