aboutsummaryrefslogtreecommitdiffstats
path: root/testing/polybar/APKBUILD
blob: cb4ba29fd9d138fff7bd0609cf97be0439d276e7 (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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# Contributor: Taner Tas <taner76@gmail.com>
# Maintainer: Taner Tas <taner76@gmail.com>
pkgname=polybar
pkgver=3.3.1
pkgrel=0
pkgdesc="A fast and easy-to-use tool for creating status bars."
url="https://polybar.github.io/"
arch="all !s390x" # s390x lacks pulseaudio
license="MIT"
makedepends="
	alsa-lib-dev
	cairo-dev
	cmake
	curl-dev
	i3wm-dev
	jsoncpp-dev
	libmpdclient-dev
	libnl3-dev
	libxcb-dev
	pulseaudio-dev
	python2
	xcb-proto
	xcb-util-cursor-dev
	xcb-util-image-dev
	xcb-util-renderutil-dev
	xcb-util-wm-dev
	xcb-util-xrm-dev
	"
subpackages="
	$pkgname-doc
	$pkgname-bash-completion:bashcomp:noarch
	$pkgname-zsh-completion:zshcomp:noarch
	"
install="
	$pkgname.post-install
	"
_xppver="56fbf8459809ba65f9ea4a65b8f467a6e9890c4e"
_i3ipcppver="0.7.1"
source="
	$pkgname-$pkgver.tar.gz::https://github.com/jaagr/polybar/archive/$pkgver.tar.gz
	xpp-$_xppver.tar.gz::https://github.com/jaagr/xpp/archive/$_xppver.tar.gz
	https://github.com/jaagr/i3ipcpp/archive/v$_i3ipcppver.tar.gz
	fix-wstringop-truncation.patch
	"
builddir="$srcdir/$pkgname-$pkgver"
options="!check" # No test suite

prepare() {
	cd "$builddir"
	mkdir -p build
	rm -rf lib/xpp
	mv "$srcdir"/xpp-$_xppver lib/xpp
	rm -rf lib/i3ipcpp
	mv "$srcdir"/i3ipcpp-$_i3ipcppver lib/i3ipcpp
	default_prepare
}

build() {
	cd "$builddir"/build
	cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release ..
	cmake --build .
}

package() {
	cd "$builddir"/build
	cmake --build . --target install -- DESTDIR="$pkgdir"
}

bashcomp() {
	pkgdesc="Bash completion for $pkgname"
	install_if="$pkgname=$pkgver-r$pkgrel bash-completion"

	mkdir -p "$subpkgdir"/usr/share/
	mv "$pkgdir"/usr/share/bash-completion \
		"$subpkgdir"/usr/share/
}

zshcomp() {
	pkgdesc="Zsh completion for $pkgname"
	install_if="$pkgname=$pkgver-r$pkgrel zsh"

	mkdir -p "$subpkgdir"/usr/share/
	mv "$pkgdir"/usr/share/zsh \
		"$subpkgdir"/usr/share/
}

sha512sums="c0bfaf99dcd19f8fcca8bd041c0f9e5f11fb822c92cf12edc2c59e67896f566ee46d1a0d75f5583d393af3a1958c3244a4eb28224f6336e9eaa98a50d740f834  polybar-3.3.1.tar.gz
22581067ddda3ac75ef2747d77ab7fc2ea228da3cd6f974533e4e2777beaacd4ca0618b8ee53ba26dd319ffeed0b317d10ca99b5a2769b9bc92841f619d3c33c  xpp-56fbf8459809ba65f9ea4a65b8f467a6e9890c4e.tar.gz
ef9f591bb4436916ad038bcb0c15ea3415d1978ff264fb276108ddac89c98515c464fbf252429f6a76589cb78e1434adba2efefb5a844dadad0e261f3806fb72  v0.7.1.tar.gz
5313c9a20b3f56d878dde0b053c8ca689bbbec077b7c7ba47549dac96393de809e14313e76f68b975f334876a472b14a4d82166c10a64623e753007b26e686ca  fix-wstringop-truncation.patch"