blob: 7b7d75bb7d3149b079de9f33d21999bc7a023d8f (
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
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=cfengine
pkgver=3.12.2
pkgrel=0
pkgdesc="A systems administration tool for networks"
url="https://www.cfengine.com/"
arch="all"
license="GPL-3.0"
install="$pkgname.post-install"
makedepends="$depends_dev lmdb-dev openssl-dev bison flex-dev
acl-dev pcre-dev linux-headers"
subpackages="$pkgname-doc $pkgname-masterfiles::noarch"
source="https://cfengine-package-repos.s3.amazonaws.com/tarballs/$pkgname-$pkgver.tar.gz
https://cfengine-package-repos.s3.amazonaws.com/tarballs/$pkgname-masterfiles-$pkgver.tar.gz"
builddir="$srcdir"/cfengine-${pkgver%_p*}
builddirmasterfiles="$srcdir"/cfengine-masterfiles-${pkgver%_p*}
options="!check" # testsuite shows some unknown errors
# secfixes:
# 3.12.2-r0:
# - CVE-2019-9929
prepare() {
default_prepare
# Also extract masterfiles
cd $srcdir
tar xf $pkgname-masterfiles-$pkgver.tar.gz
}
build() {
cd "$builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
--with-pic \
--prefix=/usr \
--enable-fhs \
--localstatedir=/var \
--mandir=/usr/share/man \
--with-lmdb \
--without-pam
make
cd "$builddirmasterfiles"
./configure \
--prefix=/var/lib/cfengine
make
}
package() {
cd "$builddir"
make install DESTDIR="$pkgdir"
# not FHS but the tools seems to require those
install -d "$pkgdir"/var/lib/cfengine/bin
for i in "$pkgdir"/usr/bin/*; do
ln -s ../../../../usr/bin/${i##*/} "$pkgdir"/var/lib/cfengine/bin/
done
}
masterfiles() {
pkgdesc="Cfengine default masterfiles"
depends="cfengine"
cd "$builddirmasterfiles"
make install DESTDIR="$subpkgdir"
}
sha512sums="fd2947c6b61dd6cc0f171ef5b74cb5908dc8494b3ed9580dea879e872580231faaf8b88c882fd7935b7315ee91a7222f949db8a37747a65c715f295756981942 cfengine-3.12.2.tar.gz
a8a861d6191055e208147765a1348a7f05a4acbc7c6305e4a8be4f68aa7318f918b28a164f856465f5d8e53b739e4a31ea8064723db0844f4a68b5eb8743d52b cfengine-masterfiles-3.12.2.tar.gz"
|