if [ $USR_JA_DEV = "ja" ] ; then
LATEX=platex
if [ -d /usr/local/teTeX/bin ] ; then
PATH=/usr/local/teTeX/bin:$PATH
fi
if [ $USR_JA_DEV = "ja" ] ; then
LATEX=platex
if [ -d /usr/local/teTeX/bin ] ; then
PATH=/usr/local/teTeX/bin:$PATH
fi
- SOURCE=m17n-lib-ja
- echo '\appendix' > app.tex
- sed -n -e '/コンパイル/,/GFDL/ p' < refman.tex >> app.tex
+ echo '\\appendix' > app.tex
+ sed -n -e '/コンパイル/,/include{m17nDBFormat}/ p' \
+ -e '/Tutorial for writing/,/include{GFDL}/ p' \
+ -e '/printindex/,$ p' < refman.tex >> app.tex
- -e '/コンパイル/,/GFDL/ d' \
- -e '/structMInputXIMArgIM/ r app.tex' \
- < refman.tex > ${SOURCE}.tex
+ -e '/inputenc/ d' \
+ -e '/コンパイル/,/include{GFDL}/ d' \
+ -e '/chapter{ファイル}/,$ d' < refman.tex > m17n-lib.tex
+ cat app.tex >> m17n-lib.tex
+ rm -rf tmp
+ mkdir tmp
+ for f in *; do
+ case "$f" in
+ m17nDBData.tex) ;;
+ *.tex) mv "$f" tmp; iconv -f utf-8 -t euc-jp < "tmp/$f" > "$f";;
+ *.sty) mv "$f" tmp; iconv -f utf-8 -t euc-jp < "tmp/$f" > "$f";;
+ esac
+ done
+ rm -rf tmp
sed -e '/documentclass/ s/a4paper/a4paper,twoside/' \
-e '/The m17n Library Module Index/,/pages/ d' \
-e '/The m17n Library File Documentation/,/textprop_8c/ d' \
-e '/The m17n Library Directory Documentation/,/dir_000001/ d' \
-e 's/The m17n Library Page Documentation/Appendix/' \
sed -e '/documentclass/ s/a4paper/a4paper,twoside/' \
-e '/The m17n Library Module Index/,/pages/ d' \
-e '/The m17n Library File Documentation/,/textprop_8c/ d' \
-e '/The m17n Library Directory Documentation/,/dir_000001/ d' \
-e 's/The m17n Library Page Documentation/Appendix/' \
- sed -n -e '/Print compile/,/GFDL/ p' < refman.tex >> app.tex
+ sed -n -e '/Print compile/,/include{GFDL}/ p' \
+ -e '/printindex/,$ p' < refman.tex >> app.tex
- -e '/Print compile/,/GFDL/ d' \
- -e '/structMInputXIMArgIM/ r app.tex' \
- < refman.tex > ${SOURCE}.tex
+ -e '/Print compile/,/include{GFDL}/ d' \
+ -e '/chapter{File Documentation}/,$ d' < refman.tex > m17n-lib.tex
+ cat app.tex >> m17n-lib.tex