[112517] trunk/dports/tex/pTeX
takanori at macports.org
takanori at macports.org
Thu Oct 24 23:43:10 PDT 2013
Revision: 112517
https://trac.macports.org/changeset/112517
Author: takanori at macports.org
Date: 2013-10-24 23:43:10 -0700 (Thu, 24 Oct 2013)
Log Message:
-----------
pTeX:
- fixed an instability issue of dvipdfmx (Ticket #39334)
- gcc48 is no longer required
- experimental support for Yu fonts (Mavericks only)
- misc fixes
Modified Paths:
--------------
trunk/dports/tex/pTeX/Portfile
trunk/dports/tex/pTeX/files/patch-2extract-src.sh.diff
trunk/dports/tex/pTeX/files/patch-7font-search.sh.diff
Added Paths:
-----------
trunk/dports/tex/pTeX/files/archive/dvipdfmx-clang-#39334.diff
Modified: trunk/dports/tex/pTeX/Portfile
===================================================================
--- trunk/dports/tex/pTeX/Portfile 2013-10-25 06:40:32 UTC (rev 112516)
+++ trunk/dports/tex/pTeX/Portfile 2013-10-25 06:43:10 UTC (rev 112517)
@@ -4,7 +4,7 @@
name pTeX
version 20110314
-revision 8
+revision 9
epoch ${version}
set ver_ptetex3 20080616
set ver_dvipdfmx 20110311
@@ -129,8 +129,12 @@
conflicts texlive-common
-default_variants +hiragino +otf
+default_variants +otf
+if {![variant_isset yu]} {
+ default_variants +hiragino
+}
+
if {[variant_isset euc] || [variant_isset sjis] || [variant_isset utf8]} {
# nop
} else {
@@ -176,8 +180,7 @@
delete ${worksrcpath}/archive/dvipsk-5.96-p1.7b.tar.gz
}
-# Ticket #39334
-configure.compiler macports-gcc-4.8
+compiler.blacklist *clang*
configure.args --without-texi2html \
--without-texinfo \
@@ -248,17 +251,27 @@
system "(cd ${workpath}/temp; tar -cf - info man) | (cd ${destroot}${prefix}/share; tar --no-same-owner -xf -)"
delete ${destroot}${prefix}/share/info/dir
+ copy ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/ptex-hiragino.map ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/ptex-yu.map
+ foreach {hira yu} {HiraMinPro-W3 YuMin-Medium.otf
+ HiraKakuPro-W6 YuGo-Bold.otf} {
+ reinplace "s|${hira}|${yu}|g" ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/ptex-yu.map
+ }
+
copy ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa.map ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa-hiraginoEmbed.map
- foreach {mori hira} {Ryumin-Light HiraMinPro-W3.otf
- GothicBBB-Medium HiraKakuPro-W3.otf
- FutoMinA101-Bold HiraMinPro-W6.otf
- FutoGoB101-Bold HiraKakuPro-W6.otf
- Jun101-Light HiraMaruPro-W4.otf} {
+ copy ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa.map ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa-yuEmbed.map
+ if {[variant_isset otf]} {copy ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/otf-hiragino.map ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/otf-yu.map}
+ foreach {mori hira yu} {Ryumin-Light HiraMinPro-W3.otf YuMin-Medium.otf
+ GothicBBB-Medium HiraKakuPro-W3.otf YuGo-Medium.otf
+ FutoMinA101-Bold HiraMinPro-W6.otf YuMin-Demibold.otf
+ FutoGoB101-Bold HiraKakuPro-W6.otf YuGo-Bold.otf
+ Jun101-Light HiraMaruPro-W4.otf HiraMaruPro-W4.otf} {
reinplace "s|${mori}|${hira}|g" ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa-hiraginoEmbed.map
+ reinplace "s|${mori}|${yu}|g" ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/morisawa-yuEmbed.map
+ if {[variant_isset otf]} {reinplace "s|${hira}|${yu}|g" ${destroot}${prefix}/share/texmf/fonts/map/dvipdfm/otf-yu.map}
}
foreach d {texmf texmf-config} {
if {[file exists ${destroot}${prefix}/share/${d}/web2c/updmap.cfg]} {
- reinplace "s|^\\(KanjiMap morisawa.map\\)$|\\1\\\n#! KanjiMap morisawa-hiraginoEmbed.map|" ${destroot}${prefix}/share/${d}/web2c/updmap.cfg
+ reinplace "s|^\\(KanjiMap morisawa.map\\)$|\\1\\\n#! KanjiMap morisawa-hiraginoEmbed.map\\\n#! KanjiMap morisawa-yuEmbed.map|" ${destroot}${prefix}/share/${d}/web2c/updmap.cfg
}
}
@@ -303,9 +316,20 @@
}
if {[variant_isset hiragino]} {
- system "${prefix}/bin/updmap-sys --setoption kanjiEmbed hiragino --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --setoption kanjiEmbed hiragino --nomkmap || true"
system "${prefix}/bin/updmap-sys --disable morisawa.map --nomkmap || true"
system "${prefix}/bin/updmap-sys --enable KanjiMap morisawa-hiraginoEmbed.map --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --disable morisawa-yuEmbed.map --nomkmap || true"
+ } elseif {[variant_isset yu]} {
+ system "${prefix}/bin/updmap-sys --setoption kanjiEmbed yu --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --disable morisawa.map --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --disable morisawa-hiraginoEmbed.map --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --enable KanjiMap morisawa-yuEmbed.map --nomkmap || true"
+ } else {
+ system "${prefix}/bin/updmap-sys --setoption kanjiEmbed noEmbed --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --enable morisawa.map --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --disable morisawa-hiraginoEmbed.map --nomkmap || true"
+ system "${prefix}/bin/updmap-sys --disable morisawa-yuEmbed.map --nomkmap || true"
}
system "${prefix}/bin/updmap-sys"
@@ -314,11 +338,13 @@
universal_variant no
-variant hiragino description {Use Hiragino fonts} {
- depends_build-delete port:ghostscript-fonts-hiragino
- depends_build-append port:ghostscript
- depends_run-delete port:ghostscript-fonts-hiragino
- depends_run-append port:ghostscript
+variant hiragino conflicts yu description {Use Hiragino fonts for typesetting} {}
+variant yu conflicts hiragino description {Use Yu fonts for typesetting (experimental; not recommended)} {
+ if {${os.platform} == "darwin" && ${os.major} >= 13} {
+ # nop
+ } else {
+ return -code error "variant +yu is supported on Mavericks or later only"
+ }
}
variant otf description {Install otf.sty} {}
@@ -327,7 +353,7 @@
variant sjis conflicts euc utf8 description {Set the default character encoding to Shift_JIS} {}
variant utf8 conflicts euc sjis description {Set the default character encoding to UTF-8} {}
-variant motif conflicts xaw xaw3d nextaw description {Use Motif to build xdvi} {
+variant motif conflicts xaw xaw3d nextaw description {Use Motif widget toolkit to build xdvi} {
depends_lib-append port:fontconfig port:freetype port:jpeg port:libiconv
depends_lib-append lib:libXm:openmotif
configure.args-delete --without-x --without-xdvik
Added: trunk/dports/tex/pTeX/files/archive/dvipdfmx-clang-#39334.diff
===================================================================
--- trunk/dports/tex/pTeX/files/archive/dvipdfmx-clang-#39334.diff (rev 0)
+++ trunk/dports/tex/pTeX/files/archive/dvipdfmx-clang-#39334.diff 2013-10-25 06:43:10 UTC (rev 112517)
@@ -0,0 +1,26 @@
+--- tetex-src-3.0/texk/dvipdfmx/src/dpxcrypt.h.orig 2011-03-06 12:14:13.000000000 +0900
++++ tetex-src-3.0/texk/dvipdfmx/src/dpxcrypt.h 2013-09-18 02:48:49.000000000 +0900
+@@ -24,10 +24,11 @@
+ #define _DPXCRYPT_H_
+
+ #include <stdio.h>
++#include <stdint.h>
+
+ /* libgcrypt md5 */
+ typedef struct {
+- unsigned long A,B,C,D; /* chaining variables */
++ uint32_t A,B,C,D; /* chaining variables */
+ unsigned long nblocks;
+ unsigned char buf[64];
+ int count;
+--- tetex-src-3.0/texk/dvipdfmx/src/dpxcrypt.c.orig 2011-03-11 12:12:23.000000000 +0900
++++ tetex-src-3.0/texk/dvipdfmx/src/dpxcrypt.c 2013-09-18 02:49:26.000000000 +0900
+@@ -281,7 +281,7 @@
+ #define X(a) do { *p++ = hd->a; *p++ = hd->a >> 8; \
+ *p++ = hd->a >> 16; *p++ = hd->a >> 24; } while (0)
+ #else /* little endian */
+-#define X(a) do { *(unsigned long *)p = (*hd).a ; p += 4; } while (0)
++#define X(a) do { *(uint32_t *)p = (*hd).a ; p += sizeof(uint32_t); } while (0)
+ #endif
+ X(A);
+ X(B);
Modified: trunk/dports/tex/pTeX/files/patch-2extract-src.sh.diff
===================================================================
--- trunk/dports/tex/pTeX/files/patch-2extract-src.sh.diff 2013-10-25 06:40:32 UTC (rev 112516)
+++ trunk/dports/tex/pTeX/files/patch-2extract-src.sh.diff 2013-10-25 06:43:10 UTC (rev 112517)
@@ -73,7 +73,7 @@
#exit # uncomment if 'mktemp' command doesn't exist
# Don't use PID for temporary file names in scripts. (impoted from FC4)
cpatch security/tetex-3.0-badscript.patch 1 $SRC
-@@ -263,7 +258,16 @@
+@@ -263,7 +258,17 @@
## check
@@ -86,6 +86,7 @@
+ cpatch archive/getline-lion.diff 1 $SRC
+ cpatch archive/pdftexdir-png15.diff 1 $SRC
+ cpatch archive/mendexk-ptex#00349.diff 1 $SRC
++ cpatch archive/dvipdfmx-clang-#39334.diff 1 $SRC
+ exit
+fi
cat <<EOF
Modified: trunk/dports/tex/pTeX/files/patch-7font-search.sh.diff
===================================================================
--- trunk/dports/tex/pTeX/files/patch-7font-search.sh.diff 2013-10-25 06:40:32 UTC (rev 112516)
+++ trunk/dports/tex/pTeX/files/patch-7font-search.sh.diff 2013-10-25 06:43:10 UTC (rev 112517)
@@ -46,7 +46,7 @@
if test -d /System/Library/Fonts; then # Mac OS X
LC_ALL=ja_JP.UTF-8
-@@ -154,18 +121,12 @@
+@@ -154,18 +121,16 @@
HiraKakuPro-W6.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5γѥ\xB4 Pro W6.otf"
HiraKakuStd-W8.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5γѥ\xB4 Std W8.otf"
HiraMaruPro-W4.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5δݥ\xB4 Pro W4.otf"
@@ -68,6 +68,10 @@
+HiraKakuProN-W6.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5γѥ\xB4 ProN W6.otf"
+HiraKakuStdN-W8.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5γѥ\xB4 StdN W8.otf"
+HiraMaruProN-W4.otf {,/System}"/Library/Fonts/\xA5ҥ饮\xA5δݥ\xB4 ProN W4.otf"
++YuGo-Bold.otf "/Library/Fonts/Yu Gothic Bold.otf"
++YuGo-Medium.otf "/Library/Fonts/Yu Gothic Medium.otf"
++YuMin-Demibold.otf "/Library/Fonts/Yu Mincho Demibold.otf"
++YuMin-Medium.otf "/Library/Fonts/Yu Mincho Medium.otf"
EOF
fi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20131024/63a787e3/attachment-0001.html>
More information about the macports-changes
mailing list