a project to simplify installation of open source software
on Mac OS X and Darwin
# $Id: Portfile 22928 2007-03-19 13:37:56Z takanori@macports.org $
PortSystem 1.0
name fontforge
version 20070312
categories graphics fonts
maintainers nomaintainer@macports.org
description Outline and bitmap font editor/converter for many formats
long_description \
FontForge allows you to edit outline and bitmap fonts. You may create \
new ones or modify old ones. It is also a format converter and can \
interconvert between PostScript (ascii & binary Type1, some Type3, \
some Type0), TrueType, OpenType (Type2), CID, SVG. Previously known as \
pfaedit.
platforms darwin
homepage http://fontforge.sourceforge.net/
master_sites sourceforge:fontforge \
${homepage}:cidmaps
distname ${name}_full-${version}
use_bzip2 yes
distfiles-append cidmaps.tgz:cidmaps
# ${name}_htdocs-${version}.tar.bz2
extract.only ${distname}${extract.suffix}
checksums ${distname}${extract.suffix} md5 f1b211fad5088764582f7b0e9d5113fc \
sha1 310c29b1905893c9dd48a7d78bd0b8c9067fafd8 \
rmd160 8acfaeecb31d1bf2644427e27b540fefddecb27c \
cidmaps.tgz md5 5f00607e4bbe014cdfd5b23bb0943666 \
sha1 d111db1f6d9a05cf6cb1387c2fb2eeb21ba0279a \
rmd160 c25b1a4f0d8ed0634402d2ce2b36ba47e0c2ef1b
# ${name}_htdocs-${version}.tar.bz2 md5 0f7b90adb0faf4b2e353ad5df9200b88 \
# sha1 56163a2ef952ca1c4b8feb25b72a50d2af09287a \
# rmd160 5afaa49f6fb22634e273ceecb9aaeece628badf9
worksrcdir ${name}-${version}
depends_lib port:libpng port:libungif port:tiff port:jpeg \
port:libuninameslist port:freetype port:gettext \
lib:libX11:XFree86 port:libiconv port:libxml2 port:zlib
patchfiles fontforge.patch
patch.pre_args -p1
post-extract {
file mkdir ${worksrcpath}/cidmap
system "cd ${worksrcpath}/cidmap && gzip -dc ${distpath}/cidmaps.tgz | tar --no-same-owner -xf -"
# file mkdir ${worksrcpath}/htdocs
# system "cd ${worksrcpath}/htdocs && bzip2 -dc ${distpath}/${name}_htdocs-${version}.tar.bz2 | tar --no-same-owner -xf -"
}
post-patch {
reinplace "s|@@PREFIX@@|${prefix}|g" ${worksrcpath}/configure
reinplace "s|@@PREFIX@@|${prefix}|g" ${worksrcpath}/gdraw/dynamic.c
}
destroot.post_args prefix=${destroot}/${prefix}
post-destroot {
delete ${destroot}/${prefix}/share/man
file rename ${destroot}/${prefix}/man ${destroot}/${prefix}/share/man
system "strip ${destroot}/${prefix}/bin/fontforge"
}
post-destroot {
xinstall -m 755 -d ${destroot}/${prefix}/share/doc/${name}
xinstall -m 644 -W ${worksrcpath} AUTHORS INSTALL LICENSE README-Mac.html \
README-Unix.html README-unix ${destroot}/${prefix}/share/doc/${name}
}
variant svg {
configure.args-append --with-multilayer
}