aboutsummaryrefslogtreecommitdiffstats
path: root/community/clsync/APKBUILD
blob: 0dd0b711c7e4501dda181d8f4e8670c992b4c2f1 (plain) (blame)
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
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=clsync
pkgver=0.4.3
pkgrel=1
pkgdesc="File live sync daemon based on inotify"
url="https://github.com/xaionaro/clsync"
arch="x86 x86_64"
license="GPL-3.0-or-later"
depends=""
depends_dev="glib-dev fts-dev libcap-dev libexecinfo-dev linux-headers musl-dev"
makedepends="$depends_dev autoconf automake file libtool"
subpackages="$pkgname-openrc $pkgname-doc $pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/xaionaro/$pkgname/archive/v$pkgver.tar.gz
	musl-fix.patch
	$pkgname.initd
	$pkgname.confd
	"
builddir="$srcdir/$pkgname-$pkgver"
options="!check"  # upstream does not provide tests

prepare() {
	default_prepare

	cd "$builddir"
	autoreconf -i
}

build() {
	cd "$builddir"

	./configure \
		CFLAGS="$CFLAGS -lfts -lexecinfo" \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--enable-capabilities \
		--enable-seccomp \
		--disable-debug
	make
}

package() {
	cd "$builddir"

	make DESTDIR="$pkgdir" install

	install -D -m 0755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
	install -D -m 0644 "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
	install -d -m 0755 "$pkgdir"/etc/$pkgname
}

sha512sums="ab803cc04cd2efd5902ea54ae3f7dc29fd88fc01b70f90112f188b60bb45fe79e255a91df3fa429d0b0f4fb6f67ea453d732a53b4db44d9f85077230d9095e4a  clsync-0.4.3.tar.gz
8211e588246a754770713be36b316a47e525f02abad580102720ecff460ed7ccb21d1e56c9c427c974747cd25c8f9c879dd89a5aaba56eeaef5d5422844885fd  musl-fix.patch
230324ec639454e614db886eb52f5c2270aae2c54ef46b62e45dba95440f55d02618fa79dccc73d20ed27012ef083cb45bdb3de8b3c4cc4ef91ba31c0e2f7c69  clsync.initd
227329c0c13c2db137d6d61905c7133fc7ca0666ceff8c14d043e2811adbe6ef5aae4c876093a4d91ec496646ccacc607c853d2c1c1a53ef6d2a4b4db9209307  clsync.confd"