2 # -*- coding: utf-8; -*-
3 # $1: target directory (usr/latex, ja/latex, or dev/latex)
4 # $2: latex commnad (latex, platex, or pdflatex)
7 USR_JA_DEV=`dirname $1`
8 TEXINPUTS=`pwd`/styles:.:
12 if [ $USR_JA_DEV = "ja" ] ; then
14 if [ -d /usr/local/teTeX/bin ] ; then
15 PATH=/usr/local/teTeX/bin:$PATH
18 sed -e '/documentclass/ s/a4paper/a4paper,twoside/' \
19 -e '/m17n ライブラリ モジュール索引/,/pages/ d' \
20 -e '/m17n ライブラリ ファイル/,/textprop_8c/ d' \
21 -e '/m17n ライブラリ Directory Documentation/,/dir_000001/ d' \
22 -e 's/m17n ライブラリ ページ/Appendix/' \
23 < refman.tex > ${SOURCE}.tex
24 elif [ $USR_JA_DEV = "dev" ] ; then
26 sed -e '/documentclass/ s/a4paper/a4paper,twoside/' \
27 -e '/The m17n Library Module Index/,/pages/ d' \
28 -e '/The m17n Library File Documentation/,/textprop_8c/ d' \
29 -e '/The m17n Library Directory Documentation/,/dir_000001/ d' \
30 -e 's/The m17n Library Page Documentation/Appendix/' \
31 < refman.tex > ${SOURCE}.tex
34 sed -e '/documentclass/ s/a4paper/a4paper,twoside/' \
35 -e '/The m17n Library Module Index/,/pages/ d' \
36 -e '/The m17n Library File Documentation/,/textprop_8c/ d' \
37 -e '/The m17n Library Directory Documentation/,/dir_000001/ d' \
38 -e 's/The m17n Library Page Documentation/Appendix/' \
39 < refman.tex > ${SOURCE}.tex
41 ${LATEX} ${SOURCE}.tex
42 #if [ "${USR_JA_DEV}" = "ja" ] ; then
43 # nkf -e < ${SOURCE}.idx > temp.idx; mv temp.idx ${SOURCE}.idx
45 /usr/bin/makeindex ${SOURCE}.idx
46 ${LATEX} ${SOURCE}.tex
47 ${LATEX} ${SOURCE}.tex