diff options
author | Seemant Kulleen <seemant@gentoo.org> | 2006-09-28 00:10:00 +0000 |
---|---|---|
committer | Seemant Kulleen <seemant@gentoo.org> | 2006-09-28 00:10:00 +0000 |
commit | c13b12e5ab69b3c202a59b961866d482ac9436bb (patch) | |
tree | f55825b8e8ee5322f01fb84b9b242c04899f17ff /app-backup/backuppc/backuppc-2.1.2-r1.ebuild | |
parent | Version bump. (diff) | |
download | gentoo-2-c13b12e5ab69b3c202a59b961866d482ac9436bb.tar.gz gentoo-2-c13b12e5ab69b3c202a59b961866d482ac9436bb.tar.bz2 gentoo-2-c13b12e5ab69b3c202a59b961866d482ac9436bb.zip |
Patch to make this work with more recent versions of rsync. Closes bug #148935 by David Relson
(Portage version: 2.1.2_pre1-r4)
Diffstat (limited to 'app-backup/backuppc/backuppc-2.1.2-r1.ebuild')
-rw-r--r-- | app-backup/backuppc/backuppc-2.1.2-r1.ebuild | 130 |
1 files changed, 130 insertions, 0 deletions
diff --git a/app-backup/backuppc/backuppc-2.1.2-r1.ebuild b/app-backup/backuppc/backuppc-2.1.2-r1.ebuild new file mode 100644 index 000000000000..bb2e647cd225 --- /dev/null +++ b/app-backup/backuppc/backuppc-2.1.2-r1.ebuild @@ -0,0 +1,130 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-backup/backuppc/backuppc-2.1.2-r1.ebuild,v 1.1 2006/09/28 00:10:00 seemant Exp $ + +inherit eutils webapp + +IUSE="samba doc" + +MY_P=BackupPC-${PV} +PATCH_VER=0.1 +S=${WORKDIR}/${MY_P} +DESCRIPTION="A high performance, enterprise grade backup system for backing up +Linux, Windows, Mac OS X desktops and laptops to a server's disk. No client +side software needed." +HOMEPAGE="http://backuppc.sourceforge.net" +SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz + mirror://gentoo/${P}-gentoo-${PATCH_VER}.tar.bz2" + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~x86" + +DEPEND="dev-lang/perl" +RDEPEND="dev-perl/File-RsyncP + app-arch/par2cmdline + app-arch/gzip + app-arch/bzip2 + app-arch/unzip + dev-perl/Archive-Zip + virtual/mta + samba? ( net-fs/samba )" + +PATCHDIR=${WORKDIR}/gentoo/prepatch + +pkg_setup() { + enewgroup backuppc + enewuser backuppc -1 -1 /dev/null backuppc + + webapp_pkg_setup +} + +src_unpack() { + unpack ${A}; cd ${S} + epatch ${FILESDIR}/${MY_P}pl2.diff + + EPATCH_SUFFIX="diff" epatch ${PATCHDIR} +} + +src_compile() { + find ./ -name 'CVS' -type d | xargs rm -rf +} + +src_test() { + einfo "Can not test" +} + +src_install() { + local myconf + if use samba ; then + myconf="--bin-path smbclient=$(type -p smbclient)" + myconf="--bin-path nmblookup=$(type -p nmblookup)" + fi + + webapp_src_preinst + + dodir ${MY_HTDOCSDIR}/${PN} + + ./configure.pl \ + --batch \ + --bin-path perl=$(type -p perl) \ + --bin-path ptar=$(type -p tar) \ + --bin-path rsync=$(type -p rsync) \ + --bin-path ping=$(type -p ping) \ + --bin-path df=$(type -p df) \ + --bin-path ssh=$(type -p ssh) \ + --bin-path sendmail=$(type -p sendmail) \ + --bin-path hostname=$(type -p hostname) \ + --bin-path gzip=$(type -p gzip) \ + --bin-path bzip2=$(type -p bzip2) \ + --bin-path hostname=$(type -p hostname) \ + --hostname XXXXXX \ + --uid-ignore \ + --install-dir=/usr \ + --dest-dir ${D} \ + --html-dir ${MY_HTDOCSDIR}/image \ + --html-dir-url /backuppc/image \ + --cgi-dir ${MY_CGIBINDIR}/ \ + --data-dir /var/lib/backuppc \ + ${myconf} || die "failed the configure.pl script" + + pod2man \ + --section=8 \ + --center="BackupPC manual" \ + ${S}/doc/BackupPC.pod backuppc.8 || die "failed to generate man page" + + doman backuppc.8 + + diropts -m 750 + keepdir /var/lib/backuppc/{trash,pool,pc,log,cpool} + + diropts -m 755 + dodir /etc/backuppc + mv ${D}/var/lib/backuppc/conf/* ${D}/etc/backuppc + rmdir ${D}/var/lib/backuppc/conf + + fperms 644 /etc/backuppc/config.pl + fperms 644 /etc/backuppc/hosts + + newinitd ${S}/init.d/gentoo-backuppc backuppc + newconfd ${S}/init.d/gentoo-backuppc.conf backuppc + + webapp_postinst_txt \ + en ${FILESDIR}/postinstall-en.txt || die "webapp_postinst_txt" + + webapp_src_install || die "webapp_src_install" + + cd ${D}/etc/backuppc + ebegin "Patching config.pl for sane defaults" + patch -p0 < ${WORKDIR}/gentoo/postpatch/config.pl.diff + eend $? + + chown -R backuppc:backuppc "${D}/var/lib/backuppc" +} + +pkg_postinst() { + webapp_pkg_postinst + + ebegin "Adjusting ownership of /var/lib/backuppc" + chown -R backuppc:backuppc "${ROOT}/var/lib/backuppc" + eend $? +} |