a project to simplify installation of open source software
on Mac OS X and Darwin
# $Id: Portfile 22478 2007-03-02 05:16:40Z pipping@macports.org $
PortSystem 1.0
name ghostview
version 1.5
categories print
maintainers nomaintainer@macports.org
description X11 frontend for ghostscript
long_description \
Ghostview is a full function user interface for Ghostscript \
(versions 2.4 and later).
homepage http://www.gnu.org/software/ghostview/
platforms darwin
master_sites gnu
depends_run bin:gs:ghostscript
checksums md5 4f5c1bced73fe14b03109cfa7aacfd90
patch {
reinplace "s|extern int sys_nerr;||" "${worksrcpath}/misc.c" "${worksrcpath}/SelFile.c"
reinplace "s|extern char .sys_errlist..;||" "${worksrcpath}/misc.c" "${worksrcpath}/SelFile.c"
}
use_xmkmf yes
pre-build {
reinplace "s|BINDIR = /usr/X11R6/bin|BINDIR = ${prefix}/bin|" "${worksrcpath}/Makefile"
reinplace "s|MANPATH = /usr/X11R6/man|MANPATH = ${prefix}/share/man|" "${worksrcpath}/Makefile"
reinplace "s|LIBDIR = /usr/X11R6/lib/X11|LIBDIR=${prefix}/share/ghostview|" "${worksrcpath}/Makefile"
}
post-destroot {
cd ${worksrcpath}
system "make DESTDIR=${destroot} install.man"
}