# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils DESCRIPTION="GtkPSproc is a front-end for the PSUTILS designed to work from all programs that uses CUPS" HOMEPAGE="http://www.rastersoft.com/gtkpsproc.html" SRC_URI="http://www.rastersoft.com/descargas/gtkpsproc31.tar.bz2" LICENSE="GPL-2" KEYWORDS="-*" IUSE="pyfam" DEPEND=" >=net-print/cups-1.1.23 >=dev-python/pygtk-2.6.1 >=app-text/psutils-1.17 pyfam? (app-admin/fam) " src_unpack() { unpack ${A} cd ${WORKDIR}/gtkpsproc31 if use pyfam; then ewarn "" ewarn "You selected fam-support. Please note that you must have" ewarn "the fam PYTHON module for this to work." ewarn "" else epatch "${FILESDIR}"/${P}-simpler_applet.patch fi epatch "${FILESDIR}"/${P}-visor_failure.patch mv Makefile Makefile.orig echo "D = ${D}" > Makefile sed -re 's/\/usr\//$(D)\/usr\//g' -e 's/\/etc\/init/#/g' -e 's/cat war/#/g' \ -e 's/lib\/cups/libexec\/cups/g' Makefile.orig >> Makefile } src_install() { mkdir -p ${D}/usr/bin mkdir -p ${D}/usr/share/pixmaps mkdir -p ${D}/usr/share/cups/model mkdir -p ${D}/usr/libexec/cups/backend cd ${WORKDIR}/gtkpsproc31 make install || die } pkg_postinst() { einfo "" einfo "The GTKPsProc virtual printer is now available." einfo "Use" einfo " lpadmin -p GtkPSproc -E -v psproc_backend:/ -m gtkpsproc" einfo "to install it. Remember to run the psproc_applet for each user" einfo "who will use GTKPsProc." einfo "Use" einfo " psproc_applet &" einfo "to do so." einfo "" }