[vine-users:082077] Re: platex での js*.cls 使用時におけるエラー

Munehiro Yamamoto munepi @ cg8.so-net.ne.jp
2012年 8月 18日 (土) 11:11:13 JST


山本@千葉のおうちです。

羽根さん、こんにちは。
> alias platex='platex -kanji=euc'
原因がこの alias であることにお気づきになられたそうで、
解決されたようで何よりです。

せっかく簡単に説明します。

■Vine Linux 5
まず、Vine Linux 5 についてです。
Vine Linux 5 の TeX 環境は、ptetex3 でした。
Vine Linux 4.2 のときも ptetex3 でしたが、
大きく違ったのは、標準の文字コードを eucjp から utf8 に変えたことです。

$ platex --version
pTeX 3.141592-p3.1.10 (utf8.euc) (Web2C 7.5.4)
kpathsea version 3.5.6
ptexenc version 0.999
Copyright (C) 1997-2004 D.E. Knuth.
Kpathsea is copyright (C) 1997-2004 Free Software Foundation, Inc.
There is NO warranty.  Redistribution of this software is
covered by the terms of both the pTeX copyright and
the GNU General Public License.
For more information about these matters, see the files
named COPYING and the pTeX source.
Primary author of TeX: D.E. Knuth.
Kpathsea written by Karl Berry and others.

$ platex -kanji=euc --version
pTeX 3.141592-p3.1.10 (euc) (Web2C 7.5.4)
kpathsea version 3.5.6
ptexenc version 0.999
Copyright (C) 1997-2004 D.E. Knuth.
Kpathsea is copyright (C) 1997-2004 Free Software Foundation, Inc.
There is NO warranty.  Redistribution of this software is
covered by the terms of both the pTeX copyright and
the GNU General Public License.
For more information about these matters, see the files
named COPYING and the pTeX source.
Primary author of TeX: D.E. Knuth.
Kpathsea written by Karl Berry and others.

Vine Linux 5 のリポジトリからインストールできる 
jsclasses の状況は、以下のようになっています。

$ kpsewhich -progname=platex jsarticle.cls
/usr/share/texmf/ptex/platex/js/jsarticle.cls
$ nkf -g $(kpsewhich -progname=platex jsarticle.cls)
ISO-2022-JP (LF)
$ rpm -qf $(kpsewhich -progname=platex jsarticle.cls)
tetex-macros-3.0-7vl5

jsarticle.cls は、JIS コードのままでした。
なので、hoge.tex の documentclass で jsarticle.cls をしていた場合、

$ nkf -g hoge
EUC-JP
$ platex -kanji=euc hoge
でも、

$ nkf -g hoge
UTF-8
$ platex -kanji=utf8 hoge
$ platex hoge
でも、問題なく typeset できていました。


■Vine Linux 6
次に、Vine Linux 6 についです。
Vine Linux 6 の TeX 環境は、TeX Live に移行しまして、
ptexlive-2009 (TeX Live 2009)でした。

$ platex --version
pTeX 3.1415926-p3.1.11 (utf8.euc) (Web2C 2009)
kpathsea version 5.0.0
ptetex 1.1.0
Copyright 2009 D.E. Knuth.
There is NO warranty.  Redistribution of this software is
covered by the terms of both the pTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pTeX source.
Primary author of pTeX: D.E. Knuth.

$ platex -kanji=euc -version
pTeX 3.1415926-p3.1.11 (euc) (Web2C 2009)
kpathsea version 5.0.0
ptetex 1.1.0
Copyright 2009 D.E. Knuth.
There is NO warranty.  Redistribution of this software is
covered by the terms of both the pTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pTeX source.
Primary author of pTeX: D.E. Knuth.

Vine Linux 6 のリポジトリからインストールできる 
jsclasses の状況は、以下のようになっています。

$ kpsewhich -progname=platex jsarticle.cls
/usr/share/texmf/ptex/platex/js/jsarticle.cls
$ nkf -g $(kpsewhich -progname=platex jsarticle.cls)
UTF-8
$ rpm -qf $(kpsewhich -progname=platex jsarticle.cls)
texlive-macros-2009-3vl6.noarch

はい、jsarticle.cls の文字コードが、UTF-8 になりました。
したがいまして、hoge.tex の documentclass で jsarticle.cls をしていた場合、

$ nkf -g hoge
EUC-JP
$ platex -kanji=euc hoge

では、typeset できません。

もちろん、
$ nkf -g hoge
UTF-8
$ platex -kanji=utf8 hoge
$ platex hoge
であれば、typeset できます。

■ CTAN に登録されている jsclasses 

jsclasses は、すでに CTAN に entry されており、
TeX Live 2011, TeX Live 2012 からいつでも取得できるようになっています。

$ /opt/texlive/2012/bin/x86_64-linux/kpsewhich -progname=platex jsarticle.cls
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/jsarticle.cls
$ nkf -g $(/opt/texlive/2012/bin/x86_64-linux/kpsewhich -progname=platex jsarticle.cls)
UTF-8
$ nkf -g /opt/texlive/2012/texmf-dist/tex/platex/jsclasses/*
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/jsarticle.cls: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/jsbook.cls: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/jspf.cls: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/jsverb.sty: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/kiyou.cls: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/minijs.sty: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/morisawa.sty: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/okumacro.sty: UTF-8
/opt/texlive/2012/texmf-dist/tex/platex/jsclasses/okuverb.sty: UTF-8

CTAN における jsclasses の文字コードは、UTF-8 になっております。
Vine Linux 6 の TeX 環境から、TeX Live に移行したことをきっかけに、
CTAN に合わせまして、jsclasses の文字コードも
意図的に UTF-8 へ変更いたしました。


以上です。
ご参考にしてくださいませ。

-- 
山本 宗宏 Munehiro "munepi" Yamamoto <munepi @ vinelinux.org>
GPG Key ID: 0xC24B55FD
GPG Key Fingerprint: 61EC 85A8 5F34 5E35 91E8  8AD0 1D28 D5DE C24B 55FD


vine-users メーリングリストの案内