1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
7 inherit autotools eutils user
9 DESCRIPTION="Network backup and restore client and server for Unix and Windows"
10 HOMEPAGE="http://burp.grke.org/"
11 SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2
12 http://burp.grke.org/downloads/${P}/${P}.tar.bz2"
17 IUSE="acl afs ipv6 libressl nls tcpd xattr"
20 !libressl? ( dev-libs/openssl:0= )
21 libressl? ( dev-libs/libressl:0= )
24 <net-libs/librsync-2.0
28 afs? ( net-fs/openafs )
29 nls? ( sys-devel/gettext )
30 tcpd? ( sys-apps/tcp-wrappers )
31 xattr? ( sys-apps/attr )
37 DOCS=( CONTRIBUTORS DONATIONS UPGRADING )
39 "${FILESDIR}/${PV}-non-zero-or-build-failure.patch"
40 "${FILESDIR}/${PV}-bedup-conf-path.patch"
41 "${FILESDIR}/${PV}-tinfo.patch"
46 enewuser "${PN}" -1 "" "" "${PN}"
50 epatch "${PATCHES[@]}"
57 --sysconfdir=/etc/burp
64 $(use_with tcpd tcp-wrappers)
66 econf "${myeconfargs[@]}"
72 fowners root:burp /etc/burp /var/spool/burp
73 fperms 0775 /etc/burp /var/spool/burp
74 fowners root:burp /etc/burp/clientconfdir
75 fperms 0750 /etc/burp/clientconfdir
76 fowners root:burp /etc/burp/burp-server.conf
77 fperms 0640 /etc/burp/burp-server.conf
79 newinitd "${FILESDIR}"/${PN}.initd ${PN}
82 sed -e 's|^# user=graham|user = burp|' \
83 -e 's|^# group=nogroup|group = burp|' \
84 -e 's|^pidfile = .*|lockfile = /run/lock/burp/server.lock|' \
85 -i "${D}"/etc/burp/burp-server.conf || die
89 if [[ ! -e /etc/burp/CA/index.txt ]]; then
90 elog "At first run burp server will generate DH parameters and SSL"
91 elog "certificates. You should adjust configuration before."
92 elog "Server configuration is located at"
94 elog " /etc/burp/burp-server.conf"