# $Id: Portfile 56055 2009-08-23 23:03:40Z ryandesign@macports.org $

PortSystem          1.0

name                pstoedit
version             3.45
revision            3
categories          graphics
maintainers         nomaintainer
description         Translate PostScript and PDF to other vector formats
long_description \
   pstoedit converts PostScript(TM) and PDF files to other vector graphic \
   formats so that they can be edited graphically.

platforms           darwin

homepage            http://www.pstoedit.net/
master_sites        sourceforge:pstoedit

checksums           md5 071efc64d9edf5d942b407348ac7451d

depends_lib         port:ImageMagick \
                    port:plotutils \
                    port:libpng \
                    port:libemf \
                    port:zlib
depends_run         port:ghostscript

patchfiles          patch-src-pstoedit.diff patch-src__cppcomp.h

configure.cppflags-append   "-Wno-long-long"

post-destroot {
   xinstall -m 755 -d ${destroot}${prefix}/share/man/man1 \
      ${destroot}${prefix}/share/doc/${name}
   xinstall -m 644 -W ${worksrcpath}/doc pstoedit.1 \
      ${destroot}${prefix}/share/man/man1
   eval xinstall -m 644 [glob ${worksrcpath}/doc/*.htm] \
      [glob ${worksrcpath}/doc/*.tex] [glob ${worksrcpath}/doc/*.txt] \
      ${destroot}${prefix}/share/doc/${name}
}

platform powerpc {
   depends_lib-delete   port:libemf
}
