aboutsummaryrefslogtreecommitdiffstats
path: root/testing/redshift/APKBUILD
blob: e7c31df5e8008a2d53c067791cf38eb7c00ba7d0 (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: 7heo <7heo@mail.com>
pkgname=redshift
pkgver=1.11
pkgrel=0
pkgdesc="Adjusts the color temperature of your screen according to your surroundings"
url="http://jonls.dk/redshift/"
arch="all"
license="GPL3"
depends=""
depends_dev=""
makedepends="libxcb-dev libxxf86vm-dev libdrm-dev intltool"
install=
replaces=""
subpackages="$pkgname-doc"
source="https://github.com/jonls/${pkgname}/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.xz"

_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
	cd "$_builddir"

	local i=
	for i in $source; do
		case "$i" in
		*.patch)
			patch -p1 -i "$srcdir"/$i || return 1 ;;
		esac
	done
}

build() {
	cd "$_builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--enable-drm \
		--enable-randr \
		--enable-vidmode \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1

	mkdir -p "$pkgdir"/usr/share/doc/$pkgname/examples
	install -m644 redshift.conf.sample \
		"$pkgdir"/usr/share/doc/$pkgname/examples/redshift.conf || return 1

	local f=
	for f in ABOUT-NLS DESIGN HACKING NEWS README README-colorramp; do
		install -m644 $f "$pkgdir"/usr/share/doc/$pkgname/$f || return 1
	done
}

md5sums="a31d768b0348c5202e58612855a9027e  redshift-1.11.tar.xz"
sha256sums="10e350f93951c0521dd6f103d67a485972c307214f036e009acea2978fe4f359  redshift-1.11.tar.xz"
sha512sums="88d7a4aabfaf3073f88673bc77df19d7bd79cb19aa8e647670cc52c02443475a4602f109fc4a06bf1639d1829d16a2644854039f90a614fc1a51c9cb4c81de16  redshift-1.11.tar.xz"