blob: 740f2d57b7f626241303b82fc8340b7dec8ce757 (
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
|
# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>
# Previous maintainer: Swift Geek <swiftgeek@gmail.com>
pkgname=earlyoom-git
pkgver=1.8.1.r1.ge6c7978
pkgrel=1
pkgdesc="Early OOM Daemon for Linux"
arch=('i686' 'x86_64')
url="https://github.com/rfjakob/earlyoom"
license=('MIT')
depends=('glibc')
makedepends=('git' 'pandoc')
checkdepends=('cppcheck' 'go')
optdepends=('systembus-notify: desktop notifications')
provides=("earlyoom=$pkgver")
conflicts=('earlyoom')
backup=("etc/default/earlyoom")
source=("git+https://github.com/rfjakob/earlyoom.git")
sha256sums=('SKIP')
prepare() {
cd "earlyoom"
sed '/systemctl|chcon/d' -ri "Makefile"
sed '/^DynamicUser=/a SupplementaryGroups=proc' -i "earlyoom.service.in"
sed 's;^EARLYOOM_ARGS="(.*)";EARLYOOM_ARGS="\1 -n --avoid '\''(^|/)(init|systemd|Xorg|sshd)$'\''";' -ri "earlyoom.default"
}
pkgver() {
cd "earlyoom"
git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "earlyoom"
make \
PREFIX="/usr"
}
check() {
cd "earlyoom"
#make test
}
package() {
cd "earlyoom"
make \
DESTDIR="$pkgdir" \
PREFIX="/usr" \
SYSTEMDUNITDIR="/usr/lib/systemd/system" \
install
install -Dm644 "LICENSE" -t "$pkgdir/usr/share/licenses/earlyoom"
}
|