From owner-svn-ports-head@FreeBSD.ORG Sat Jul 5 05:28:31 2014 Return-Path: Delivered-To: svn-ports-head@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 87517C1; Sat, 5 Jul 2014 05:28:31 +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)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6897F2757; Sat, 5 Jul 2014 05:28:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s655SVfC023038; Sat, 5 Jul 2014 05:28:31 GMT (envelope-from leeym@svn.freebsd.org) Received: (from leeym@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s655SUTf023035; Sat, 5 Jul 2014 05:28:30 GMT (envelope-from leeym@svn.freebsd.org) Message-Id: <201407050528.s655SUTf023035@svn.freebsd.org> From: Yen-Ming Lee Date: Sat, 5 Jul 2014 05:28:30 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r360720 - in head/chinese: cwtexttf fireflyttf ttfm X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 05 Jul 2014 05:28:31 -0000 Author: leeym Date: Sat Jul 5 05:28:30 2014 New Revision: 360720 URL: http://svnweb.freebsd.org/changeset/ports/360720 QAT: https://qat.redports.org/buildarchive/r360720/ Log: - support stage and options Modified: head/chinese/cwtexttf/Makefile head/chinese/fireflyttf/Makefile head/chinese/ttfm/Makefile.ttf Modified: head/chinese/cwtexttf/Makefile ============================================================================== --- head/chinese/cwtexttf/Makefile Sat Jul 5 04:55:30 2014 (r360719) +++ head/chinese/cwtexttf/Makefile Sat Jul 5 05:28:30 2014 (r360720) @@ -18,11 +18,10 @@ WRKSRC= ${WRKDIR}/texmf/fonts/truetype/ TTF= bbttf.ttf fttf.ttf kttf.ttf mttf.ttf rttf.ttf -NO_STAGE= yes do-install: - @${MKDIR} ${FONTSDIR} + @${MKDIR} ${STAGEDIR}${FONTSDIR} .for i in ${TTF} - ${INSTALL_DATA} ${WRKSRC}/${i} ${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${FONTSDIR} .endfor .include Modified: head/chinese/fireflyttf/Makefile ============================================================================== --- head/chinese/fireflyttf/Makefile Sat Jul 5 04:55:30 2014 (r360719) +++ head/chinese/fireflyttf/Makefile Sat Jul 5 05:28:30 2014 (r360720) @@ -22,7 +22,6 @@ LGJ_FONT_DESC= Patch for Taiwan horn TTF= fireflysung.ttf -NO_STAGE= yes .include .if ${PORT_OPTIONS:MLGJ_FONT} @@ -48,9 +47,9 @@ post-extract: .endif do-install: - ${MKDIR} ${FONTSDIR} - ${INSTALL_DATA} ${WRKSRC}/${TTF} ${FONTSDIR} - ${INSTALL_DATA} ${FILESDIR}/local.conf-sung ${FONTSDIR} + ${MKDIR} ${STAGEDIR}${FONTSDIR} + ${INSTALL_DATA} ${WRKSRC}/${TTF} ${STAGEDIR}${FONTSDIR} + ${INSTALL_DATA} ${FILESDIR}/local.conf-sung ${STAGEDIR}${FONTSDIR} .if ${PORT_OPTIONS:MX11} ${INSTALL_DATA} ${FILESDIR}/local.conf-sung ${LOCALBASE}/etc/fonts/local.conf .endif Modified: head/chinese/ttfm/Makefile.ttf ============================================================================== --- head/chinese/ttfm/Makefile.ttf Sat Jul 5 04:55:30 2014 (r360719) +++ head/chinese/ttfm/Makefile.ttf Sat Jul 5 05:28:30 2014 (r360720) @@ -7,10 +7,11 @@ # The variable(s) for installing TrueType fonts. # TTF - Name(s) of font file(s) installed in FONTSDIR. Mandatory. # -# The variable(s) to change the behavior of installing TrueType fonts. -# WITH_GS - Add Ghostscript support -# WITHOUT_X11 - Remove X Window support -# + +OPTIONS_DEFINE+= GHOSTSCRIPT X11 +OPTIONS_DEFAULT+= X11 + +.include FONTSDIR?= ${PREFIX}/share/fonts/TrueType FONTSDIR_REL= ${FONTSDIR:S,^${PREFIX}/,,} @@ -20,12 +21,12 @@ XFONTSDIR?= ${LOCALBASE}/lib/X11/fonts/T XFONTSDIR_REL= ${XFONTSDIR:S,${LOCALBASE}/,,} PLIST_SUB+= XFONTSDIR=${XFONTSDIR_REL} -.if !defined(WITHOUT_X11) +.if ${PORT_OPTIONS:MX11} RUN_DEPENDS+= ${LOCALBASE}/bin/fc-cache:${PORTSDIR}/x11-fonts/fontconfig _TTF_MODULES= xttfm .endif -.if defined(WITH_GS) +.if ${PORT_OPTIONS:MGHOSTSCRIPT} RUN_DEPENDS+= ${LOCALBASE}/share/fonts/adobe-cmaps/ai0/CMap/Identity-H:${PORTSDIR}/print/adobe-cmaps _TTF_MODULES+= gscjk .endif @@ -37,12 +38,12 @@ RUN_DEPENDS+= ${PREFIX}/bin/ttfm.sh:${PO check-makefile: check-makefile-ttf check-makefile-ttf: .if !defined(_TTF_MODULES) - @${ECHO_CMD} "Makefile warning: You choose neither X11 nor GS. Only font files themselves are installed" + @${ECHO_CMD} "Makefile warning: You choose neither X11 nor GHOSTSCRIPT. Only font files themselves are installed" .else @${ECHO_CMD} "" @${ECHO_CMD} "You may use the following options:" - @${ECHO_CMD} " WITH_GS - if you want Ghostscript support" - @${ECHO_CMD} " WITHOUT_X11 - if you DON'T want X Window support" + @${ECHO_CMD} " ${OPTIONS_NAME}_SET=GHOSTSCRIPT - if you want Ghostscript support" + @${ECHO_CMD} " ${OPTIONS_NAME}_UNSET=X11 - if you DON'T want X Window support" @${ECHO_CMD} "" .endif .if !defined(TTF) @@ -57,19 +58,19 @@ do-install-ttf: .endif .for module in ${_TTF_MODULES} . for ttf in ${TTF} - ${PREFIX}/bin/ttfm.sh --add ${module} ${FONTSDIR}/${ttf} + ${PREFIX}/bin/ttfm.sh --add ${module} ${STAGEDIR}${FONTSDIR}/${ttf} . endfor .endfor -.if !defined(WITHOUT_X11) +.if ${PORT_OPTIONS:MX11} @${ECHO_MSG} "===> Running fc-cache" - -@${LOCALBASE}/bin/fc-cache -f -v ${XFONTSDIR} + -@${LOCALBASE}/bin/fc-cache -f -v ${STAGEDIR}${XFONTSDIR} .endif add-plist-post: add-plist-ttf add-plist-ttf: .for module in ${_TTF_MODULES} . for ttf in ${TTF} - @${ECHO_CMD} "@unexec %D/bin/ttfm.sh --remove ${module} ${FONTSDIR}/${ttf} || true" >> ${TMPPLIST} + @${ECHO_CMD} "@unexec %D/bin/ttfm.sh --remove ${module} ${STAGEDIR}${FONTSDIR}/${ttf} || true" >> ${TMPPLIST} . endfor .endfor .for ttf in ${TTF} @@ -77,15 +78,15 @@ add-plist-ttf: .endfor .for module in ${_TTF_MODULES} . for ttf in ${TTF} - @${ECHO_CMD} "@exec %D/bin/ttfm.sh --add ${module} ${FONTSDIR}/${ttf} || true" >> ${TMPPLIST} + @${ECHO_CMD} "@exec %D/bin/ttfm.sh --add ${module} ${STAGEDIR}${FONTSDIR}/${ttf} || true" >> ${TMPPLIST} . endfor .endfor -.if !defined(WITHOUT_X11) +.if ${PORT_OPTIONS:MX11} @${ECHO_CMD} "@unexec ${LOCALBASE}/bin/fc-cache -f -v ${XFONTSDIR} || true" >> ${TMPPLIST} @${ECHO_CMD} "@exec ${LOCALBASE}/bin/fc-cache -f -v ${XFONTSDIR} || true" >> ${TMPPLIST} @${ECHO_CMD} "@unexec find ${XFONTSDIR} -size -3c -delete || true" >> ${TMPPLIST} - @${ECHO_CMD} "@unexec rmdir ${XFONTSDIR} 2>/dev/null || true" >> ${TMPPLIST} + @${ECHO_CMD} "@dirrmtry ${XFONTSDIR}" >> ${TMPPLIST} .endif - @${ECHO_CMD} "@unexec rmdir ${FONTSDIR} 2>/dev/null || true" >> ${TMPPLIST} - @${ECHO_CMD} "@unexec rmdir %D/share/fonts 2>/dev/null || true" >> ${TMPPLIST} + @${ECHO_CMD} "@dirrmtry ${FONTSDIR}" >> ${TMPPLIST} + @${ECHO_CMD} "@dirrmtry share/fonts" >> ${TMPPLIST}