# Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils DESCRIPTION="Utah Raster Toolkit - tools for manipulation of RLE images." HOMEPAGE="http://www.cs.utah.edu/gdc/projects/${PN}/" SRC_URI="ftp://ftp.iastate.edu/pub/utah-raster/${PN}-${PV}.tar.Z" LICENSE="other" SLOT="0" KEYWORDS="~x86" IUSE="X gif tiff targa pbm" DEPEND="tiff? (media-libs/tiff) \ X? (virtual/x11)" RDEPEND="" src_unpack() { cd ${WORKDIR} mkdir ${P} cd ${S} unpack ${A} epatch ${FILESDIR}/${PF}-gentoo.diff } src_compile() { chmod u+w ${S}/config/urt einfo Injecting portage CFLAGS to urt config file. echo >>${T}/urt.conf ExtraCFLAGS=${CFLAGS} if use X; then einfo Compiling with X11 support. echo >>${T}/urt.conf "#define X11" fi if use gif; then einfo Compiling with gif support. echo >>${T}/urt.conf "#define GIF" fi if use tiff; then einfo Compiling with tiff support. echo >>${T}/urt.conf "#define TIFF" fi if use targa; then einfo Compiling with targa support. echo >>${T}/urt.conf "#define TARGA" fi if use pbm; then einfo Compiling with pbm support. echo >>${T}/urt.conf "#define PBM" fi cat >>${T}/urt.conf ${S}/config/urt mv ${T}/urt.conf ${S}/config/urt cd ${S}/man cat makefile.src | awk -f ../makedef.awk > makefile cd ${S} ./Configure config/urt emake || die "emake failed" } src_install() { einfo install cd ${S} mkdir -p ${D}/usr/bin ${D}/usr/share/man/man3 ${D}/usr/share/man/man1 \ ${D}/usr/share/man/man5 ${D}/usr/lib ${D}/usr/include make install dodoc ${S}/3.1-changes ${S}/CHANGES{,.raw} ${S}/README ${S}/MANIFEST.new \ ${S}/copyright }