blob: 55fbaa504772e69df7823faecd1b75fef1f86f87 (
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
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=cfengine
pkgver=3.15.0
pkgrel=0
pkgdesc="A systems administration tool for networks"
url="https://www.cfengine.com/"
arch="all"
license="GPL-3.0-only"
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/cfengine-$pkgver.tar.gz
https://cfengine-package-repos.s3.amazonaws.com/tarballs/cfengine-masterfiles-$pkgver.tar.gz"
_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() {
./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() {
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="de15d8c7b84eadf6a042a89cdf45cda7bb8f0eace3936a7f5699bde9a06a6ee203348e2b11236b55052cdb1008c83687ef282e7bf662c9f9ad3db11cf4429f58 cfengine-3.15.0.tar.gz
a5f1f6b5275ee3e8e913aafad2598f76406ba61ea5b5692da23fed7a5fdbd9828c5b9b5fd51ae080e628c483197469c9cc19f8f786b5496fcbbfebeaac1b414b cfengine-masterfiles-3.15.0.tar.gz"
|