aboutsummaryrefslogtreecommitdiffstats
path: root/main/backuppc/APKBUILD
blob: 08f8206d7ec2e7c12aabd877e54a2f4eb9953567 (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
73
74
# Contributor:
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname="backuppc"
_realname="BackupPC"
pkgver=3.3.0
_realver=$pkgver
pkgrel=1
pkgdesc="High-performance, enterprise-grade backup system"
url="http://backuppc.sourceforge.net/"
arch="noarch"
license="GPL2+"
depends="perl busybox rsync perl-archive-zip perl-io-compress 
	perl-libwww perl-file-rsync"
makedepends=""
install="$pkgname.pre-install $pkgname.post-install"
subpackages=""
source="http://downloads.sourceforge.net/project/$pkgname/$pkgname/$_realver/$_realname-$_realver.tar.gz
	configure.pl.patch"

_builddir="$srcdir/$_realname-$_realver"
prepare () {
	cd "$_builddir"
	mkdir -p "$pkgdir"/etc/BackupPC
	mkdir -p "$pkgdir"/var/www/cgi-bin
	patch -p2 < ../../configure.pl.patch
}

build() {
	return 0
}

package() {
	cd "$_builddir"
	perl configure.pl \
	 --batch \
	 --backuppc-user=backuppc \
	 --bin-path bzip2=/usr/bin/bzip2 \
	 --bin-path cat=/bin/cat \
	 --bin-path df=/bin/df \
	 --bin-path tar=/bin/tar \
	 --bin-path hostname=/bin/hostname \
	 --bin-path nmblookup=/usr/bin/nmblookup \
	 --bin-path perl=/usr/bin/perl \
	 --bin-path ping=/bin/ping \
	 --bin-path rsync=/usr/bin/rsync \
	 --bin-path sendmail=/usr/bin/sendmail \
	 --bin-path smbclient=/usr/bin/smbclient \
	 --bin-path split=/usr/bin/split \
	 --bin-path ssh=/usr/bin/ssh \
	 --compress-level=3 \
	 --dest-dir="$pkgdir" \
	 --config-dir /etc/BackupPC \
	 --cgi-dir /var/www/cgi-bin \
	 --data-dir /var/lib/BackupPC \
	 --hostname backuppc \
	 --html-dir /var/www/htdocs/BackupPC \
	 --html-dir-url /BackupPC \
	 --install-dir /usr/lib/BackupPC \
	 --log-dir /var/log/BackupPC \
	 --uid-ignore \
	 --no-set-perms || return 1

	install -m755 configure.pl "$pkgdir"/usr/lib/BackupPC/bin/configure.pl

	chmod 774 "$pkgdir"/usr/lib/BackupPC/bin/*

}

md5sums="2942a31daeec7c7bb227d843b7846f38  BackupPC-3.3.0.tar.gz
f57ad7fdcce804f20f2fe82bee91e813  configure.pl.patch"
sha256sums="8a9c1b6faa4502b4c40617be97e806813815d9e22544854d99983c3da7c1f69b  BackupPC-3.3.0.tar.gz
f07039e6bf25fc19bc0bc894d6dd6ff0348612a95a24e68b181da94b9f5ddd0c  configure.pl.patch"
sha512sums="67ec1ca4d22ab1e81f9c0f409c758347a6c772e3d1aa39c93207f9d328176ac7b4e679d0b03972fc5870c37dde0480d28c61ae19975d54e144235ea0e84e9901  BackupPC-3.3.0.tar.gz
7ea98de0960cd0ea4f64e71c61e4565a73db2fd872d2f102dc08543ad60eb1cf986b9c0a32b7b4694dc9a8ffe2cd6bd7ca3ff2cc0b4d91961952664b62881faf  configure.pl.patch"