diff options
Diffstat (limited to 'print/gsfonts/Makefile')
-rw-r--r-- | print/gsfonts/Makefile | 83 |
1 files changed, 61 insertions, 22 deletions
diff --git a/print/gsfonts/Makefile b/print/gsfonts/Makefile index ad9456c79de6..1ebfbadce0dc 100644 --- a/print/gsfonts/Makefile +++ b/print/gsfonts/Makefile @@ -6,36 +6,75 @@ # PORTNAME= gsfonts -PORTVERSION= 6.0 -CATEGORIES= print -MASTER_SITES= ${MASTER_SITE_GNU} \ - ftp://ftp.cs.wisc.edu/ghost/gnu/ -MASTER_SITE_SUBDIR= ghostscript +PORTVERSION= 8.11 +CATEGORIES= print x11-fonts +MASTER_SITES= ftp://mirror.cs.wisc.edu/pub/mirrors/ghost/fonts/ DISTFILES= ${GS_FONTS_STD} ${GS_FONTS_OTHER} DIST_SUBDIR= ghostscript MAINTAINER= ports@FreeBSD.org COMMENT= Fonts used by GNU Ghostscript (or X) -BUILD_DEPENDS= ${LOCALBASE}/bin/type1inst:${PORTSDIR}/x11-fonts/p5-type1inst - -.include <bsd.port.pre.mk> -.if ${XFREE86_VERSION} == 4 -BUILD_DEPENDS+= ${X11BASE}/bin/mkfontdir:${PORTSDIR}/x11/XFree86-4-clients -.else -BUILD_DEPENDS+= ${X11BASE}/bin/mkfontdir:${PORTSDIR}/x11/XFree86 -.endif +BUILD_DEPENDS= type1inst:${PORTSDIR}/x11-fonts/p5-type1inst +NO_WRKSUBDIR= yes NO_BUILD= yes -GS_FONTS_STD= gnu-gs-fonts-std-${PORTVERSION}.tar.gz -GS_FONTS_OTHER= gnu-gs-fonts-other-${PORTVERSION}.tar.gz -GSDIR= ${PREFIX}/share/ghostscript +PLIST_SUB= FONTSDIR="${FONTSDIR:S|${PREFIX}/||}" + +MSG_FILE= ${PKGDIR}/pkg-message +PKGMESSAGE= ${WRKDIR}/pkg-message + +# +# Local variables +# + +FONTSDIR?= ${PREFIX}/share/ghostscript/fonts +GS_FONTS_STD= ghostscript-fonts-std-8.11.tar.gz +GS_FONTS_OTHER= ghostscript-fonts-other-6.0.tar.gz + +.SILENT: + +post-patch: + ${SED} 's|%%FONTSDIR%%|${FONTSDIR}|g' ${MSG_FILE} > ${PKGMESSAGE} -do-install: - @${MKDIR} ${GSDIR} - ${TAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/${GS_FONTS_OTHER} -C ${GSDIR} - ${TAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/${GS_FONTS_STD} -C ${GSDIR} - (cd ${GSDIR}/fonts; ${LOCALBASE}/bin/type1inst -nox -nolog -q) +# + +# +# Install +# + +do-install: install-foundries install-fonts install-docs + +install-foundries: + ${CAT} ${WRKSRC}/fonts/fonts.scale | \ + ${SED} -e 's|-URW-|-Adobe-|g' | \ + ${SED} -e 's|-urw-|-adobe-|g' > \ + ${WRKSRC}/fonts/fonts.scale + ${CAT} ${WRKSRC}/fonts/fonts.dir | \ + ${SED} -e 's|-URW-|-Adobe-|g' | \ + ${SED} -e 's|-urw-|-adobe-|g' > \ + ${WRKSRC}/fonts/fonts.dir + +install-fonts: + ${MKDIR} ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/COPYING ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/*.afm ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/*.gsf ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/*.pfa ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/*.pfb ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/*.pfm ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/fonts.dir ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/fonts.scale ${FONTSDIR} + (cd ${FONTSDIR}; ${LOCALBASE}/bin/type1inst -nox -nolog -q) + +install-docs: +.if !defined(NOPORTDOCS) + ${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/ChangeLog ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/README ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/README.tweaks ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/fonts/TODO ${DOCSDIR} +.endif -.include <bsd.port.post.mk> +.include <bsd.port.mk> |