Annotation of OpenXM_contrib2/windows/help/makehelp2.bat, Revision 1.6
1.6 ! ohara 1: @rem $OpenXM: OpenXM_contrib2/windows/help/makehelp2.bat,v 1.5 2016/06/29 13:29:46 ohara Exp $
! 2: @echo off
! 3:
! 4: setlocal
! 5:
! 6: set PATH=..;..\..;%PATH%;c:\cygwin\bin;c:\cygwin64\bin
! 7: set lang=%~1
! 8: set PERL=perl
! 9:
! 10: REM 相対パスを絶対パスに変換する
! 11: REM 重要!! %%~fi と ) の間に空白を入れてはならない!!
! 12: for %%i in ( ..\..\..\OpenXM\src ) do (set oxsrc=%%~fi)
! 13: for %%i in ( ..\..\asir2000\lib ) do (set srcdir4=%%~fi)
! 14:
! 15: set srcdir1=%oxsrc%\asir-doc
! 16: set srcdir2=%oxsrc%\asir-contrib\packages\doc
! 17: set srcdir3=%oxsrc%\asir-contrib\packages\src
! 18:
! 19: mkdir %lang%
! 20: pushd %lang%
! 21:
! 22: REM case 1: asir 標準マニュアル
! 23:
! 24: mkdir asir\parts\builtin
! 25: pushd asir
! 26:
! 27: for %%i in ( texinfo.tex texinfo.ini txi-ja.tex txi-en.tex ) do (
! 28: nkf32 -e %srcdir1%\%%i > %%i
! 29: )
! 30:
! 31: for %%i in ( man.texi parts\algnum.texi parts\appendix.texi parts\asir.texi parts\builtin.texi parts\debug.texi parts\ff.texi parts\groebner.texi parts\intro.texi parts\process.texi parts\risa.texi parts\type.texi parts\builtin\array.texi parts\builtin\bit.texi parts\builtin\function.texi parts\builtin\io.texi parts\builtin\list.texi parts\builtin\misc.texi parts\builtin\module.texi parts\builtin\num.texi parts\builtin\numeric.texi parts\builtin\poly.texi parts\builtin\string.texi parts\builtin\structure.texi parts\builtin\type.texi parts\builtin\upoly.texi ) do (
! 32: extract_man %lang% %srcdir1%\%%i | nkf32 -e > %%i
! 33: )
! 34:
! 35: %PERL% ../../texi2html -menu -split_node man.texi
! 36: call :html_euc_to_sjis
! 37: popd
! 38:
! 39: gen_hh asir .
! 40: hhc asirhelp.hhp
! 41:
! 42: REM case 2: asir-contrib マニュアル
! 43:
! 44: mkdir cman
! 45: pushd cman
! 46:
! 47: nkf32 -e %srcdir2%\top\cman-%lang%.texi > cman-%lang%.texi
! 48: nkf32 -e %srcdir3%\names.rr > names.rr
! 49:
! 50: for %%i in ( base calculus complex glib graphic hypergeometric intro load matrix misc names number oxrfc100 oxshell poly print series util windows ) do (
! 51: nkf32 -e %srcdir2%\top\%%i.oxw | oxweave C %lang% > %%i.%lang%
! 52: )
! 53:
! 54: for %%i in ( base matrix number poly print util ) do (
! 55: oxweave usage < names.rr | oxgentexi --category %%i --%lang% --upnode %%i --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i > %%i-auto.%lang%
! 56: )
! 57:
! 58: for %%i in ( glib ) do (
! 59: nkf32 -e %srcdir4%\%%i | oxweave usage | oxgentexi --category %%i --%lang% --upnode %%i --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i > %%i-auto.%lang%
! 60: )
! 61:
! 62: for %%i in ( oxshell ) do (
! 63: nkf32 -e %srcdir3%\%%i.rr | oxweave usage | oxgentexi --category %%i --%lang% --upnode %%i --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i > %%i-auto.%lang%
! 64: )
! 65:
! 66: %PERL% ../../texi2html -menu -split_node cman-%lang%.texi
! 67: call :html_euc_to_sjis
! 68: popd
! 69:
! 70: gen_hh cman . %lang%
! 71: hhc cmanhelp.hhp
! 72:
! 73: REM 個別の場合
! 74:
! 75: REM case 3a: *.{oxg,oxw} から生成。
! 76:
! 77: for %%i in ( dsolv gnuplot mathematica ok_diff ok_dmodule phc tigers ) do (
! 78: mkdir %%i
! 79: pushd %%i
! 80: nkf32 -e %srcdir2%\%%i\%%i.oxg | oxweave usage-%lang% | oxgentexi --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i --title "%%i manual" > %%i-%lang%.texi
! 81: nkf32 -e %srcdir2%\%%i\%%i.oxw | oxweave C %lang% > %%i.%lang%
! 82: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 83: call :html_euc_to_sjis
! 84: popd
! 85: gen_hh %%i . %lang%
! 86: hhc %%ihelp.hhp
! 87: )
! 88:
! 89: REM case 3b: plucker, sm1: *.{oxg,oxw,rr} から生成。
! 90:
! 91: for %%i in ( plucker sm1 ) do (
! 92: mkdir %%i
! 93: pushd %%i
! 94: nkf32 -e %srcdir2%\%%i\%%i.oxg | oxweave usage-%lang% | oxgentexi --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i --title "%%i manual" > %%i-%lang%.texi
! 95: nkf32 -e %srcdir2%\%%i\%%i.oxw | oxweave C %lang% > %%i.%lang%
! 96: nkf32 -e %srcdir3%\%%i.rr | oxweave usage | oxgentexi --category %name% --en --upnode %%i --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i > %%i-auto.%lang%
! 97: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 98: call :html_euc_to_sjis
! 99: popd
! 100: gen_hh %%i . %lang%
! 101: hhc %%ihelp.hhp
! 102: )
! 103:
! 104: REM case 3c: pfpcoh: *.{oxg,oxw,rr} から生成。
! 105:
! 106: for %%i in ( pfpcoh ) do (
! 107: mkdir %%i
! 108: pushd %%i
! 109: nkf32 -e %srcdir2%\%%i\%%i.oxg | oxweave usage-%lang% | oxgentexi --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i --title "%%i manual" > %%i-%lang%.texi
! 110: nkf32 -e %srcdir2%\%%i\%%i.oxw | oxweave C %lang% > %%i.%lang%
! 111: nkf32 -e %srcdir3%\%%i.rr %srcdir3%\pfphom.rr | oxweave usage | oxgentexi --%lang% --upnode %%i --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i > %%i-auto.%lang%
! 112: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 113: call :html_euc_to_sjis
! 114: popd
! 115: gen_hh %%i . %lang%
! 116: hhc %%ihelp.hhp
! 117: )
! 118:
! 119: REM case 3d: om: *.{oxg,rr} から生成。
! 120:
! 121: for %%i in ( om ) do (
! 122: mkdir %%i
! 123: pushd %%i
! 124: nkf32 -e %srcdir2%\%%i\%%i.oxg | oxweave usage-%lang% | oxgentexi --noSorting --author "OpenXM.org" --infoName asir-contrib-%%i --title "%%i manual" > %%i-%lang%.texi
! 125: echo /*^&%lang% > %%i.oxw
! 126: nkf32 -e %srcdir3%\%%i.rr >> %%i.oxw
! 127: echo */ >> %%i.oxw
! 128: oxweave C %lang% < %%i.oxw > %%i.%lang%
! 129: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 130: call :html_euc_to_sjis
! 131: popd
! 132: gen_hh %%i . %lang%
! 133: hhc %%ihelp.hhp
! 134: )
! 135:
! 136: REM case 4a: *.texi から生成。
! 137:
! 138: for %%i in ( nn_ndbf ) do (
! 139: mkdir %%i
! 140: pushd %%i
! 141: nkf32 -e %srcdir2%\%%i\%%i.texi > %%i.texi
! 142: extract_man %lang% %%i.texi > %%i-%lang%.texi
! 143: oxreplace --old @fref --new @ref %%i-%lang%.texi
! 144: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 145: call :html_euc_to_sjis
! 146: popd
! 147: gen_hh %%i . %lang%
! 148: hhc %%ihelp.hhp
! 149: )
! 150:
! 151: REM case 4b: *-{ja,en}.texi から生成。
! 152:
! 153: for %%i in ( ns_twistedlog ) do (
! 154: mkdir %%i
! 155: pushd %%i
! 156: nkf32 -e %srcdir2%\%%i\%%i-%lang%.texi > %%i-%lang%.texi
! 157: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 158: call :html_euc_to_sjis
! 159: popd
! 160: gen_hh %%i . %lang%
! 161: hhc %%ihelp.hhp
! 162: )
! 163:
! 164: REM case 4c: *-ja.texi から生成。日本語のみ。
! 165:
! 166: for %%i in ( noro_matrix noro_mwl noro_pd todo_parametrize ) do (
! 167: if exist %srcdir2%\%%i\%%i-%lang%.texi (
! 168: mkdir %%i
! 169: pushd %%i
! 170: nkf32 -e %srcdir2%\%%i\%%i-%lang%.texi > %%i-%lang%.texi
! 171: %PERL% ../../texi2html -menu -split_node %%i-%lang%.texi
! 172: call :html_euc_to_sjis
! 173: popd
! 174: gen_hh %%i . %lang%
! 175: hhc %%ihelp.hhp
! 176: )
! 177: )
! 178:
! 179: popd
! 180:
! 181: exit /b 0
! 182:
! 183: :html_euc_to_sjis
! 184: for %%i in ( *.html ) do (
! 185: rename %%i __tmp
! 186: nkf32 -Es __tmp > %%i
! 187: del /q __tmp
! 188: )
! 189:
! 190: exit /b 0
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>