From owner-svn-ports-all@FreeBSD.ORG Wed Nov 13 19:10:25 2013 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A70DAC5F; Wed, 13 Nov 2013 19:10:25 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 95C6728CD; Wed, 13 Nov 2013 19:10:25 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rADJAP5N055576; Wed, 13 Nov 2013 19:10:25 GMT (envelope-from mi@svn.freebsd.org) Received: (from mi@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id rADJAOlN055571; Wed, 13 Nov 2013 19:10:24 GMT (envelope-from mi@svn.freebsd.org) Message-Id: <201311131910.rADJAOlN055571@svn.freebsd.org> From: Mikhail Teterin Date: Wed, 13 Nov 2013 19:10:24 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r333715 - in head/russian/koi8r-ps: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Nov 2013 19:10:25 -0000 Author: mi Date: Wed Nov 13 19:10:24 2013 New Revision: 333715 URL: http://svnweb.freebsd.org/changeset/ports/333715 Log: . Improve spelling a little. . Use GhostScript itself to find the Fontmap.GS -- instead of trying to parse the output of `gs -h' . Other minor improvements to scripts. Submitted by: pkg-fallout@ Added: head/russian/koi8r-ps/files/find-fontmap.sh (contents, props changed) Modified: head/russian/koi8r-ps/Makefile (contents, props changed) head/russian/koi8r-ps/files/Fontmap.diff (contents, props changed) head/russian/koi8r-ps/pkg-descr (contents, props changed) Modified: head/russian/koi8r-ps/Makefile ============================================================================== --- head/russian/koi8r-ps/Makefile Wed Nov 13 19:09:26 2013 (r333714) +++ head/russian/koi8r-ps/Makefile Wed Nov 13 19:10:24 2013 (r333715) @@ -20,19 +20,7 @@ NO_STAGE= yes .include .if !defined(FONTMAP) -FONTMAP!= if which gs > /dev/null 2>&1 ; then \ - d=`gs -h | awk '/^Search path:$$/ { nl=1; next } \ - nl { print $$3; exit }'`; \ - if [ -e $$d/Fontmap.GS ] ; then \ - ${ECHO_CMD} $$d/Fontmap.GS; \ - elif [ -e $$d/Fontmap ] ; then \ - ${ECHO_CMD} $$d/Fontmap \ - else \ - ${ECHO_CMD} /nicht/ ; \ - fi; \ - else \ - ${ECHO_CMD} /nicht/ ; \ - fi; ${ECHO_CMD} +FONTMAP!= ${SH} ${FILESDIR}/find-fontmap.sh .endif NO_PACKAGE= Nothing to build, configurations only @@ -46,7 +34,7 @@ do-extract: > ${WRKSRC}/XFree86-Type1_fonts.dir.scale do-build: - ${ECHO_CMD} `${GREP} koi8 ${WRKSRC}/XFree86-Type1_fonts.dir.scale | wc -l` \ + ${GREP} -c koi8 ${WRKSRC}/XFree86-Type1_fonts.dir.scale \ > ${WRKSRC}/fonts.dir ${GREP} koi8 ${WRKSRC}/XFree86-Type1_fonts.dir.scale \ >> ${WRKSRC}/fonts.dir @@ -61,7 +49,7 @@ do-install: ${DISTDIR}/${DIST_SUBDIR}/gs-type1_koi8_fonts.tgz ${TAR} -C ${CPS_DIR} -xzpf \ ${DISTDIR}/${DIST_SUBDIR}/gs-type1_koi8_afm.tgz -.if ${FONTMAP} == "/nicht/" +.if !exists(${FONTMAP}) ################################################################# ### You do not appear to have GhostScript installed. The file ### ${CPS_DIR}/Fontmap.diff Modified: head/russian/koi8r-ps/files/Fontmap.diff ============================================================================== --- head/russian/koi8r-ps/files/Fontmap.diff Wed Nov 13 19:09:26 2013 (r333714) +++ head/russian/koi8r-ps/files/Fontmap.diff Wed Nov 13 19:10:24 2013 (r333715) @@ -1,8 +1,8 @@ ---- Fontmap.orig Mon Jan 25 12:39:01 1999 +--- Fontmap Mon Jan 25 12:39:01 1999 +++ Fontmap Fri Jul 23 16:48:39 1999 -@@ -400,0 +401,42 @@ +@@ -350,0 +350,42 @@ + -+% Cyrrillic koi8 fonts/aliases ++% Cyrillic KOI8 fonts/aliases + +/ArialCyrMT (arial8.pfb) ; +/Arial /ArialCyrMT ; Added: head/russian/koi8r-ps/files/find-fontmap.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/russian/koi8r-ps/files/find-fontmap.sh Wed Nov 13 19:10:24 2013 (r333715) @@ -0,0 +1,19 @@ +#!/bin/sh + +if ! which gs > /dev/null ; then + echo GhostScript not found in PATH >&2 + exit 1 +fi + +# Use the method suggested here: +# http://stackoverflow.com/questions/19958156/how-to-print-the-fontresourcedir-with-ghostscript-gs +# until a better way is proposed.. +FONTPATH=`gs -dNODISPLAY -q -- /dev/stdin << EOSCRIPT +%! +/Font /Category findresource +begin + / 128 string ResourceFileName = +end +EOSCRIPT` + +echo `dirname $FONTPATH`/Init/Fontmap.GS Modified: head/russian/koi8r-ps/pkg-descr ============================================================================== --- head/russian/koi8r-ps/pkg-descr Wed Nov 13 19:09:26 2013 (r333714) +++ head/russian/koi8r-ps/pkg-descr Wed Nov 13 19:10:24 2013 (r333715) @@ -13,4 +13,4 @@ Fontmap file to print/display with this Note, however, that this will NOT make your PostScript printers print in Russian, since they have their own PostScript interpreters built in. Use -`koify' port for to deal with those. +`koify' to deal with those.