# Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ MY_P=${P/_/-} DESCRIPTION="Extremely fast and lightweight tabbed file manager" HOMEPAGE="http://pcmanfm.sourceforge.net/" SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz" LICENSE="GPL-2" SLOT="0" KEYWORDS="~amd64 ~x86" IUSE="debug hal" RDEPEND="virtual/fam x11-libs/cairo >=x11-libs/gtk+-2.8 x11-misc/shared-mime-info x11-libs/startup-notification hal? ( sys-apps/hal )" DEPEND="${RDEPEND} dev-util/pkgconfig" S=${WORKDIR}/${MY_P} src_unpack() { unpack ${A} cd "${S}" if ! use debug ; then # Disable debugging messages: # First we try to catch g_debug-messages over multiple lines # and but it on a single line. sed -i -e :a -e '/\g_debug\(.*\),$/N; s/\,\n//; ta' src/*.c src/*/*.c && # then we comment every g_debug-message out. sed -i -r \ -e "s:g_debug:// g_debug:g" \ src/*.c src/*/*.c || die "sed debug failed" fi } src_compile() { econf \ $(use_enable hal) \ || die "econf failed" emake || die "emake failed" } src_install() { emake DESTDIR="${D}" install || die "emake install failed" dodoc AUTHORS TODO } pkg_postinst() { if has_version app-admin/fam ; then elog "You are using fam as your file alteration monitor," elog "so must have famd started before running pcmanfm." elog elog "To add famd to the default runlevel and start it, run:" elog elog "# rc-update add famd default" elog "# /etc/init.d/famd start" elog elog "It is recommended to use gamin instead of fam." fi }