summaryrefslogtreecommitdiff
blob: 86a8c84a43ee763bc98c848b7a94ea6f3907c0b1 (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
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-backup/rear/rear-1.15-r1.ebuild,v 1.1 2013/10/26 13:37:26 tomwij Exp $

EAPI="5"

inherit eutils

DESCRIPTION="Fully automated disaster recovery supporting a broad variety of backup strategies and scenarios."
HOMEPAGE="http://relax-and-recover.org/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64"

IUSE="udev"

RDEPEND="dev-libs/openssl
	net-dialup/mingetty
	net-fs/nfs-utils
	sys-apps/iproute2
	sys-apps/lsb-release
	sys-apps/util-linux
	sys-block/parted
	sys-boot/syslinux
	virtual/cdrtools
	udev? ( virtual/udev )
"

src_prepare () {
	epatch "${FILESDIR}/${P}-add-support-for-gentoo-kernels.patch"
}

src_compile () { :; }

src_install () {
	# Deploy udev USB rule and udev will autostart ReaR workflows in case a USB
	# drive with the label 'REAR_000' is connected, which in turn is the
	# default label when running the `rear format` command.
	if use udev ; then
		insinto /lib/udev/rules.d
		doins etc/udev/rules.d/62-${PN}-usb.rules
	fi

	# Copy main script-file and documentation.
	dosbin usr/sbin/${PN}
	doman doc/${PN}.8
	dodoc README

	# Copy configurations files.
	insinto /etc
	doins -r etc/${PN}/

	insinto /usr/share/
	doins -r usr/share/${PN}/
}