-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPKGBUILD
35 lines (31 loc) · 899 Bytes
/
PKGBUILD
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
# Maintainer: Guillaume DELVIT <[email protected]>
_pkgname=zram-init
pkgname=${_pkgname}-git
pkgver=10.5.r0.gb91acc4
pkgrel=1
pkgdesc="Setup zram-based tmpfs and swap devices on boot"
arch=('any')
url="http://en.wikipedia.org/wiki/ZRam"
license=('GPL')
depends=('bash')
#backup=("modprobe.d/zram.conf")
source=(
"$pkgname::git+https://github.com/vaeth/zram-init.git#branch=master"
)
md5sums=('SKIP')
pkgver() {
cd "${srcdir}/${pkgname}" || exit 2
set -o pipefail
git describe --tags --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "${srcdir}/${pkgname}"
make
}
package() {
cd "${srcdir}/${pkgname}"
install -Dm755 sbin/zram-init $pkgdir/usr/bin/zram-init
install -Dm644 modprobe.d/zram.conf $pkgdir/etc/modprobe.d/zram.conf
install -Dm644 openrc/conf.d/zram-init $pkgdir/etc/conf.d/zram-init
install -Dm755 openrc/init.d/zram-init $pkgdir/etc/init.d/zram-init
}