summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 081f205158d269bbe009f0d14403019902616ca0 (plain)
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
# Maintainer: Jonathon Fernyhough <jonathon at_manjaro dot_org>
# Contributor: Aleksej Komarov <stylemistake@gmail.com>
# Contributor: MKzero <info[at]linux-web-development[dot]de>
# Upstream: Bitwig GmbH <support@bitwig.com>

# Original PKGBUILD taken wholesale from stylemistake's bitwig-studio package
# JF added a prepare() to allow side-by-side installation with release version

# As of 2.5beta4, Bitwig have moved the beta packages and you'll need to log in
# to download the source deb package. I asked about it but they're keeping it
# that way. :(

pkgname=bitwig-studio-beta
_pkgname=bitwig-studio
pkgver=3.0beta8
_pkgver=3.0
pkgrel=1
pkgdesc='Digital audio workstation for music production, remixing and live performance'
arch=('x86_64')
url='https://www.bitwig.com/'
license=('custom')
# Deps from bitwig-studio package
#depends=('jack' 'xdg-utils' 'zenity' 'xcb-util-wm' 'libbsd')
# Deps as suggested by namcap...
depends=('jack' 'gtk2' 'gtk3' 'lib32-gcc-libs' 'libbsd' 'xcb-util' 'xcb-util-wm' 'xdg-utils' 'zenity')
optdepends=('alsa-lib' 'oss' 'ffmpeg: MP3 support')
provides=('bitwig-studio')
options=(!strip)
#source=("https://downloads.bitwig.com/beta/${_pkgver}/bitwig-studio-${pkgver}.deb")
source=("local://bitwig-studio-${pkgver}.deb")
sha256sums=('b7b1d55eef194d9a9e63a9e1b3aa2d24a02cdd43e32b7acaf02b979b3f8917b1')

prepare() {
	msg2 "Unpacking archive contents..."
	bsdtar -xf ${srcdir}/data.tar.xz -C ${srcdir}/

	msg2 "Moving things around so we can install side-by-side with bitwig-studio..."
	cd ${srcdir}/opt/
	mv ${_pkgname} ${pkgname}

	cd ${srcdir}/usr/
	rm bin/${_pkgname}
	ln -s /opt/${pkgname}/${_pkgname} bin/${pkgname}

	cd share/
	mv applications/${_pkgname}.desktop applications/${pkgname}.desktop
	sed -i "s|${_pkgname}|${pkgname}|g;
	        7s|Studio|Studio Beta|;
	        11s|bitwig-|bitwig-beta-|g" applications/${pkgname}.desktop

	mv mime/packages/${_pkgname}.xml  mime/packages/${pkgname}.xml
	sed -i "s|bitwig-|bitwig-beta-|g;
	        s|Studio |Studio Beta |g" mime/packages/${pkgname}.xml

	cd icons/hicolor/
	for icon in 48x48/apps/*.png scalable/apps/*.svg; do
		mv "$icon" "${icon/./-beta.}"
	done
	for icon in scalable/mimetypes/*.svg; do
		mv "$icon" "${icon/bitwig-/bitwig-beta-}"
	done
}

package() {
	mv ${srcdir}/{opt,usr} ${pkgdir}/

	# Install license
	install -D -m644 ${pkgdir}/opt/${pkgname}/EULA.rtf ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
}