# $Id: Portfile,v 1.6 2005/10/19 08:10:08 blb Exp $

PortSystem			1.0
name				t1lib
version				5.0.2
revision			1
categories			devel graphics fonts
maintainers			blb@opendarwin.org
description			Library for generating glyphs from Type 1 fonts
long_description \
	t1lib is a library distributed under the GNU General Public Library \
	License for generating character- and string-glyphs from Adobe Type 1 \
	fonts under UNIX. t1lib uses most of the code of the X11 rasterizer \
	donated by IBM to the X11-project. But some disadvantages of the \
	rasterizer being included in X11 have been eliminated.

platforms			darwin

master_sites		http://sunsite.rediris.es/sites2/ibiblio.org/linux/libs/graphics/ \
					http://ftp.surfnet.nl/pub/sunsite/libs/graphics/ \
					opendarwin::lt

checksums			${distname}${extract.suffix} md5 \
						cc5d4130b25bb8a1c930488b78930e9b \
						sha1 71a6ec6c84a2e28a21f261be865e0dabe52daeb5 \
					ltconfig13 md5 ea53f42a550c9f9e653758a8ed91574e \
						sha1 f48ac8711e15b81e4c67ec276fa58f1da4668b6e \
					ltmain13 md5 e094ae92724c4015dbab97de151c2525 \
						sha1 e5cb21161c8377f77f0725c7ede672c0f8167783

patchfiles			patch-doc_Makefile.in patch-type1afm_Makefile.in \
					patch-lib_Makefile.in patch-xglyph_Makefile.in \
					patch-doc_t1lib_doc.tex

configure.args		--without-x

build.target		without_doc

variant x11 {
	depends_lib-append		lib:libX11:XFree86
	configure.args-delete	--without-x
	configure.args-append	--with-x
}

variant psdoc {
	depends_lib-append		bin:tex:teTeX
	build.target			all
}

variant darwin {
	distfiles-append	ltconfig13:lt ltmain13:lt
	extract.only		${distname}${extract.suffix}
	post-patch {
		xinstall -m 644 ${distpath}/ltconfig13 ${worksrcpath}/ac-tools/ltconfig
		xinstall -m 644 ${distpath}/ltmain13 ${worksrcpath}/ac-tools/ltmain.sh
	}
}

