# Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ DESCRIPTION="Easy to use GUI & CLI alternative for etc-update..." HOMEPAGE="http://people.zeelandnet.nl/xentric/cfg-update/" SRC_URI="http://people.zeelandnet.nl/xentric/cfg-update/${PF}.tar.gz" LICENSE="GPL-2" SLOT="0" KEYWORDS="x86 ppc sparc alpha mips hppa arm amd64 ia64" RDEPEND=">=dev-lang/perl-5.0 >=sys-apps/textutils-2.0 >=sys-apps/gawk-3.0 >=sys-apps/grep-2.0 >=dev-util/xxdiff-2.9 >=app-portage/gentoolkit-0.1.30" src_unpack() { unpack ${PF}.tar.gz } pkg_preinst() { einfo "Removing old script (non-ebuild version)..." rm /usr/local/bin/cfg-update 2>/dev/null einfo "Removing old checksum-index..." rm /etc/cfg-update.index 2>/dev/null } pkg_prerm() { einfo "Removing checksum-index..." rm /usr/lib/cfg-update/checksum.index 2>/dev/null einfo "Disabling alias for emerge in /etc/profile..." cfg-update --off } src_install() { exeinto /usr/lib/${PN} doexe ${PN}.pl dodir /usr/bin dosym /usr/lib/${PN}/${PN}.pl /usr/bin/${PN} insinto /usr/lib/${PN} doins .bashrc doins .bash_profile doins .Xdefaults doins README doins COPYING doins ChangeLog doman *.8 } pkg_postinst() { einfo "Checking root environment..." cfg-update --check einfo "Creating alias for emerge in /etc/profile..." cfg-update --on einfo "Sourcing /etc/profile..." source /etc/profile 2>/dev/null einfo "Creating checksum-index..." cfg-update --index }