aboutsummaryrefslogtreecommitdiffstats
path: root/community/slock/APKBUILD
blob: 82b77809d20535d8c69f6aac7cf8d6286c1aad9f (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net>
pkgname=slock
pkgver=1.4
pkgrel=0
pkgdesc="A simple screen locker for X"
url="https://tools.suckless.org/slock/"
arch="all"
license="MIT"
depends=""
depends_dev=""
makedepends="libxext-dev libxrandr-dev linux-headers"
install=""
options="suid"
subpackages="$pkgname-doc"
source="https://dl.suckless.org/tools/$pkgname-$pkgver.tar.gz"

# secfixes:
#   1.3-r3:
#     - CVE-2016-6866

builddir="$srcdir/$pkgname-$pkgver"
prepare() {
	default_prepare || return 1
	sed -i -e '/CFLAGS/{s/-Os//;s/=/+=/}' \
		-e '/LDFLAGS/{s/-s//;s/=/+=/}' \
		"$builddir"/config.mk || return 1
}

build() {
	make X11INC=/usr/include/X11 X11LIB=/usr/lib/X11 \
		-C "$builddir" || return 1
}

package() {
	make PREFIX=/usr DESTDIR="$pkgdir" \
		-C "$builddir" install || return 1
}

sha512sums="ad285360dd3f16a225159abaf2f82fabf2c675bd74478cf717f68cbe5941a6c620e3c88544ce675ce3ff19af4bb0675c9405685e0f74ee4e84f7d34c61a0532f  slock-1.4.tar.gz"