version 1.3, 2005/02/09 03:25:50 |
version 1.11, 2007/03/17 10:18:54 |
|
|
#$OpenXM: OpenXM/src/asir-contrib/packages/doc/Makefile.in,v 1.2 2004/07/15 05:39:08 takayama Exp $ |
#$OpenXM: OpenXM/src/asir-contrib/packages/doc/Makefile.in,v 1.10 2006/02/08 04:23:11 takayama Exp $ |
# targets |
RM=rm |
# all : |
|
# Extracts all tex-info files from ../src/* and generate *.texi files. |
|
# install : install-help |
|
# install-help : all |
|
# Installing online help to OpenXM/lib/asir/help-* |
|
# install-document : all gen-dvi-ps |
|
# Copy the documents in dvi and ps to OpenXM/doc/asir-contrib |
|
# install-html-help |
|
# Copy html help to OpenXM/doc/asir-contrib |
|
# gen-html-en gen-html-ja |
|
# Generate HTML documents under html-en and html-ja |
|
# gen-help-en gen-help-ja |
|
# Generate help files. |
|
# gen-dvi-ps |
|
# Generate dvi and ps files. |
|
# |
|
# NOTE: install-help should be executed after installing asir2000. |
|
######################################################################## |
|
# How to add new documents in the category xxx |
|
# "xxx*.texi <--- xxx.oxweave (manually written) + xxx*-auto.{en,ja} (automatic)" |
|
# (1) "xxx.oxweave" --> xxx.en and xxx.ja |
|
# xxx-auto.en and xxx-auto.ja should be included from |
|
# xxx.en and xxx.ja (JASRCS, ENSRCS) |
|
# NOTE: xxx.oxweave might be embedded in xxx.rr or xxx, |
|
# but this style is obsolete. |
|
# (2) "xxx.rr" or "xxx" --> xxx-auto.en and xxx-auto.ja |
|
# (JAAUTO, ENAUTO) |
|
# xxx-auto*.texi's are extracted from xxx or xxx.rr |
|
# (3) xxx.en and xxx.ja should be included from cman.texi |
|
# and cman-en.texi |
|
# cf. glib* base* |
|
######################################################################## |
|
OpenXM_ROOT=../../../../../OpenXM |
|
ASIRDOC=../../../asir-doc |
|
ASIRLIB=${OpenXM_ROOT}/../OpenXM_contrib2/asir2000/lib |
|
CONTRIB=../src |
|
OPTGENTEXI= --include |
|
#OPTGENTEXI= --include --example |
|
## PS documents are installed under ${OpenXM_doc}/asir-contrib |
|
INSTALL_doc=@prefix@/doc |
INSTALL_doc=@prefix@/doc |
INSTALL_lib=@prefix@/lib |
INSTALL_lib=@prefix@/lib |
OXWEAVE=@prefix@/bin/oxweave |
OXWEAVE=@prefix@/bin/oxweave |
DVIPS=dvips -f |
OXGENTEXI=@prefix@/bin/oxgentexi |
TEXI2HTML=texi2html -menu -split_node |
OXREPLACE=@prefix@/bin/oxreplace |
RM=rm |
|
DVIPDF=dvipdfmx |
|
|
|
SRC = base.oxweave calculus.oxweave complex.oxweave dsolv.oxweave \ |
SUBDIRS=dsolv gnuplot mathematica ok_diff ok_dmodule om \ |
glib.oxweave gnuplot.oxweave graphic.oxweave hypergeometric.oxweave \ |
pfpcoh phc plucker sm1 tigers \ |
intro.oxweave m.oxweave matrix.oxweave misc.oxweave names.oxweave \ |
todo_parametrize f_res top |
number.oxweave oxrfc100.oxweave pfp.oxweave phc.oxweave \ |
|
plucker.oxweave poly.oxweave print.oxweave series.oxweave sm1.oxweave \ |
|
tigers.oxweave util.oxweave windows.oxweave oxshell.oxweave |
|
|
|
ENSRCS = ${SRC:.oxweave=.en} opening.texi oxom.en |
all : |
JASRCS = ${SRC:.oxweave=.ja} opening.texi oxom.ja Diff-ja.texi Dmodule-ja.texi |
|
ENAUTO= base-auto.en glib-auto.en matrix-auto.en number-auto.en pfp-auto.en \ |
|
plucker-auto.en poly-auto.en print-auto.en sm1-auto.en util-auto.en \ |
|
oxshell-auto.en |
|
JAAUTO=${ENAUTO:.en=.ja} |
|
|
|
.SUFFIXES: .en .ja .oxweave .dvi .pdf |
install : |
|
@if [ ! -f ./.install_help_done ] ; then \ |
.oxweave.en: |
make install-help ; \ |
${RM} -f ${<:.oxweave=.en} |
touch ./.install_help_done ; \ |
${OXWEAVE} C en < $< > ${<:.oxweave=.en} |
|
|
|
.oxweave.ja: |
|
${RM} -f ${<:.oxweave=.ja} |
|
${OXWEAVE} C ja < $< > ${<:.oxweave=.ja} |
|
|
|
.dvi.pdf: |
|
${DVIPDF} $< |
|
|
|
all : gentexi ${JASRCS} ${ENSRCS} ${JAAUTO} ${ENAUTO} |
|
@echo "Type in tex cman-en.texi to generate the manual(en) in dvi format." |
|
@echo "Type in ptex cman-ja.texi to generate the manual(ja) in dvi format." |
|
|
|
install : |
|
@if [ ! -f ./.done_install ] ; then \ |
|
make install2 ; \ |
|
touch ./.done_install ; \ |
|
else \ |
else \ |
echo "NOTE: Installation is already done. Remove .done_install for a new installation." ; \ |
echo "NOTE: Installation of document is already done. Remove .install_help_done for a new installation." ; \ |
fi |
fi |
|
install-help: install-help-en install-help-ja |
install-document : install-html-help |
install-document : |
@if [ ! -f ./.done_install_document ] ; then \ |
@if [ ! -f ./.install_document_done ] ; then \ |
make install-document2 ; \ |
${RM} -rf ${INSTALL_doc}/asir-contrib/ja ; \ |
touch ./.done_install_document ; \ |
${RM} -rf ${INSTALL_doc}/asir-contrib/en ; \ |
|
make install-html-doc ; \ |
|
make fix-links ; \ |
|
make install-dvi-ps-pdf-doc ; \ |
|
touch ./.install_document_done ; \ |
else \ |
else \ |
echo "NOTE: Installation of document is already done. Remove .done_install_document for a new installation." ; \ |
echo "NOTE: Installation of document is already done. Remove .install_document_done for a new installation." ; \ |
fi |
fi |
|
install-html-doc: install-html-doc-en install-html-doc-ja |
|
install-dvi-ps-pdf-doc: install-dvi-ps-pdf-doc-en install-dvi-ps-pdf-doc-ja |
|
|
install2 : install-help |
install-help-en: |
|
-${RM} -rf ${INSTALL_lib}/asir/help-eg/xm.help |
|
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-help-en); done |
|
|
gentexi : gentexi.c |
install-help-ja: |
gcc -o gentexi gentexi.c |
-${RM} -rf ${INSTALL_lib}/asir/help-jp/xm.help |
|
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-help-ja); done |
|
|
oxom.ja : ${CONTRIB}/om |
install-html-doc-en: |
${RM} -f oxom.ja |
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-html-en); done |
${OXWEAVE} C ja <${CONTRIB}/om >oxom.ja |
|
oxom.en : ${CONTRIB}/om |
|
${RM} -f oxom.en |
|
${OXWEAVE} C en <${CONTRIB}/om >oxom.en |
|
|
|
### base |
install-html-doc-ja: |
base-auto.en : ${CONTRIB}/names.rr gentexi |
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-html-ja); done |
${RM} -f base-auto.en |
|
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category base --en --upnode "Basic (Standard Functions)" ${OPTGENTEXI} >base-auto.en |
|
base-auto.ja : ${CONTRIB}/names.rr gentexi |
|
${RM} -f base-auto.ja |
|
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category base --ja --upnode "Basic (Standard Functions)" ${OPTGENTEXI} >base-auto.ja |
|
|
|
### plucker |
install-dvi-ps-pdf-doc-en: |
plucker-auto.en : ${CONTRIB}/plucker.rr gentexi |
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-dvi-ps-pdf-en); done |
${RM} -f plucker-auto.en |
|
${OXWEAVE} usage <${CONTRIB}/plucker.rr | ./gentexi --category plucker --en --upnode "Plucker relations" ${OPTGENTEXI} >plucker-auto.en |
|
plucker-auto.ja : ${CONTRIB}/plucker.rr gentexi |
|
${RM} -f plucker-auto.ja |
|
${OXWEAVE} usage <${CONTRIB}/plucker.rr | ./gentexi --category plucker --ja --upnode "Plucker relations" ${OPTGENTEXI} >plucker-auto.ja |
|
|
|
### number |
install-dvi-ps-pdf-doc-ja: |
number-auto.en : ${CONTRIB}/names.rr gentexi |
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' install-dvi-ps-pdf-ja); done |
${RM} -f number-auto.en |
|
cat ${CONTRIB}/names.rr | ${OXWEAVE} usage | ./gentexi --category number --en --upnode "Numbers (Standard Mathematical Functions)" ${OPTGENTEXI} >number-auto.en |
|
number-auto.ja : ${CONTRIB}/names.rr gentexi |
|
${RM} -f number-auto.ja |
|
cat ${CONTRIB}/names.rr | ${OXWEAVE} usage | ./gentexi --category number --ja --upnode "Numbers (Standard Mathematical Functions)" ${OPTGENTEXI} >number-auto.ja |
|
|
|
### matrix |
fix-links: fix-links-en fix-links-ja |
matrix-auto.en : ${CONTRIB}/names.rr gentexi |
fix-links-ja: |
${RM} -f matrix-auto.en |
cp top/fix-link.sh ${INSTALL_doc}/asir-contrib/ja/cman-html |
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category matrix --en --upnode "Matrix (Standard Mathematical Functions)" ${OPTGENTEXI} >matrix-auto.en |
(cd ${INSTALL_doc}/asir-contrib/ja/cman-html; sh ./fix-link.sh ja ${OXREPLACE}) |
matrix-auto.ja : ${CONTRIB}/names.rr gentexi |
fix-links-en: |
${RM} -f matrix-auto.ja |
cp top/fix-link.sh ${INSTALL_doc}/asir-contrib/en/cman-html |
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category matrix --ja --upnode "Matrix (Standard Mathematical Functions)" ${OPTGENTEXI} >matrix-auto.ja |
(cd ${INSTALL_doc}/asir-contrib/en/cman-html; sh ./fix-link.sh en ${OXREPLACE}) |
|
|
### print |
clean: |
print-auto.en : ${CONTRIB}/names.rr gentexi |
-${RM} -rf ./.*done config.log config.status autom4te.cache |
${RM} -f print-auto.en |
for i in ${SUBDIRS}; do (cd $$i; make clean); done |
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category print --en --upnode "Print (Standard Mathematical Functions)" ${OPTGENTEXI} >print-auto.en |
distclean: clean |
print-auto.ja : ${CONTRIB}/names.rr gentexi |
-${RM} -rf ${INSTALL_lib}/asir/help-eg/xm.help |
${RM} -f print-auto.ja |
-${RM} -rf ${INSTALL_lib}/asir/help-jp/xm.help |
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category print --ja --upnode "Print (Standard Mathematical Functions)" ${OPTGENTEXI} >print-auto.ja |
-${RM} -rf ${INSTALL_doc}/asir-contrib |
|
-${RM} -rf ${INSTALL_doc}/asir-contrib |
|
|
### poly |
|
poly-auto.en : ${CONTRIB}/names.rr gentexi |
|
${RM} -f poly-auto.en |
|
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category poly --en --upnode "Polynomials (Standard Mathematical Functions)" ${OPTGENTEXI} >poly-auto.en |
|
poly-auto.ja : ${CONTRIB}/names.rr gentexi |
|
${RM} -f poly-auto.ja |
|
${OXWEAVE} usage <${CONTRIB}/names.rr | ./gentexi --category poly --ja --upnode "Polynomials (Standard Mathematical Functions)" ${OPTGENTEXI} >poly-auto.ja |
|
### sm1 |
|
sm1-auto.en : ${CONTRIB}/sm1 gentexi |
|
${RM} -f sm1-auto.en |
|
${OXWEAVE} usage <${CONTRIB}/sm1 | ./gentexi --category sm1 --en --upnode "SM1 Functions" ${OPTGENTEXI} >sm1-auto.en |
|
sm1-auto.ja : ${CONTRIB}/sm1 gentexi |
|
${RM} -f sm1-auto.ja |
|
${OXWEAVE} usage <${CONTRIB}/sm1 | ./gentexi --category sm1 --ja --upnode "SM1 Functions" ${OPTGENTEXI} >sm1-auto.ja |
|
|
|
### glib |
|
glib-auto.en : ${ASIRLIB}/glib gentexi |
|
${RM} -f glib-auto.en |
|
cat ${ASIRLIB}/glib | ${OXWEAVE} usage | ./gentexi --category glib --en --upnode "Graphic Library (2 dimensional)" ${OPTGENTEXI} >glib-auto.en |
|
glib-auto.ja : ${ASIRLIB}/glib gentexi |
|
${RM} -f glib-auto.ja |
|
cat ${ASIRLIB}/glib | ${OXWEAVE} usage | ./gentexi --category glib --ja --upnode "Graphic Library (2 dimensional)" ${OPTGENTEXI} >glib-auto.ja |
|
|
|
### pfp |
# For a test. |
pfp-auto.en : ${CONTRIB}/pfpcoh.rr ${CONTRIB}/pfphom.rr gentexi |
gen-help-ja: |
${RM} -f pfp-auto.en |
-for i in ${SUBDIRS}; do (cd $$i; make INSTALL_doc='${INSTALL_doc}' INSTALL_lib='${INSTALL_lib}' OXWEAVE='${OXWEAVE}' OXGENTEXI='${OXGENTEXI}' gen-help-ja); done |
cat ${CONTRIB}/pfpcoh.rr ${CONTRIB}/pfphom.rr | ${OXWEAVE} usage | ./gentexi --en --upnode Pfpcohom ${OPTGENTEXI} >pfp-auto.en |
|
pfp-auto.ja : ${CONTRIB}/pfpcoh.rr ${CONTRIB}/pfphom.rr gentexi |
|
${RM} -f pfp-auto.ja |
|
cat ${CONTRIB}/pfpcoh.rr ${CONTRIB}/pfphom.rr | ${OXWEAVE} usage | ./gentexi --ja --upnode Pfpcohom ${OPTGENTEXI} >pfp-auto.ja |
|
|
|
### util |
|
util-auto.en : ${CONTRIB}/names.rr gentexi |
|
${RM} -f util-auto.en |
|
cat ${CONTRIB}/names.rr | ${OXWEAVE} usage | ./gentexi --category util --en --upnode "Utility Functions" ${OPTGENTEXI} >util-auto.en |
|
util-auto.ja : ${CONTRIB}/names.rr gentexi |
|
${RM} -f util-auto.ja |
|
cat ${CONTRIB}/names.rr | ${OXWEAVE} usage | ./gentexi --category util --ja --upnode "Utility Functions" ${OPTGENTEXI} >util-auto.ja |
|
### oxshell |
|
oxshell-auto.en : ${CONTRIB}/oxshell.rr gentexi |
|
${RM} -f oxshell-auto.en |
|
cat ${CONTRIB}/oxshell.rr | ${OXWEAVE} usage | ./gentexi --category oxshell --en --upnode "Oxshell Functions" ${OPTGENTEXI} >oxshell-auto.en |
|
oxshell-auto.ja : ${CONTRIB}/oxshell.rr gentexi |
|
${RM} -f oxshell-auto.ja |
|
cat ${CONTRIB}/oxshell.rr | ${OXWEAVE} usage | ./gentexi --category oxshell --ja --upnode "Oxshell Functions" ${OPTGENTEXI} >oxshell-auto.ja |
|
|
|
### Generating online manual |
|
gen-help-en: ${ENSRCS} ${ASIRDOC}/extract_func ${ENAUTO} |
|
-${RM} -rf tmp-en help-en |
|
mkdir help-en tmp-en |
|
cp cman-en.texi ${ENSRCS} ${ENAUTO} tmp-en |
|
-(cd tmp-en; makeinfo --force cman-en.texi) |
|
(cd help-en; for i in ../tmp-en/asir-contrib*; do ../${ASIRDOC}/extract_func $$i; done) |
|
|
|
gen-help-ja: ${JASRCS} ${ASIRDOC}/extract_func ${JAAUTO} |
|
-${RM} -rf tmp-ja help-ja |
|
mkdir help-ja tmp-ja |
|
for i in cman-ja.texi ${JASRCS} ${JAAUTO}; do nkf -e $$i > tmp-ja/$$i; done |
|
-(cd tmp-ja; makeinfo --force cman-ja.texi) |
|
(cd help-ja; for i in ../tmp-ja/asir-contrib*; do ../${ASIRDOC}/extract_func -j $$i; done) |
|
|
|
gen-html-en: gen-help-en |
|
-${RM} -rf html-en |
|
-mkdir html-en |
|
-cp tmp-en/*.texi tmp-en/*.en html-en |
|
-(cd html-en; ${TEXI2HTML} cman-en.texi) |
|
|
|
gen-html-ja: gen-help-ja |
|
-mkdir html-ja |
|
-cp tmp-ja/*.texi tmp-ja/*.ja html-ja |
|
-cp tmp-ja/cman-ja.texi html-ja/cman-ja.texi |
|
-(cd html-ja; ${TEXI2HTML} cman-ja.texi) |
|
|
|
install-help: |
|
-make install-help-en |
|
-make install-help-ja |
|
|
|
install-help-ja: gen-help-ja |
|
${RM} -rf ${INSTALL_lib}/asir/help-jp/xm.help |
|
mkdir ${INSTALL_lib}/asir/help-jp/xm.help |
|
-cp -r -f help-ja/* ${INSTALL_lib}/asir/help-jp/xm.help |
|
install-help-en: gen-help-en |
|
${RM} -rf ${INSTALL_lib}/asir/help-eg/xm.help |
|
mkdir ${INSTALL_lib}/asir/help-eg/xm.help |
|
-cp -r -f help-en/* ${INSTALL_lib}/asir/help-eg/xm.help |
|
|
|
install-html-help: gen-html-en gen-html-ja |
|
-mkdir ${INSTALL_doc}/asir-contrib |
|
-( tar cf - html-en | (cd ${INSTALL_doc}/asir-contrib ; tar xf -)) |
|
-( tar cf - html-ja | (cd ${INSTALL_doc}/asir-contrib ; tar xf -)) |
|
|
|
install-document2 : gen-dvi-ps |
|
-mkdir ${INSTALL_lib}/asir-contrib |
|
-cp cman-ja.dvi ${INSTALL_doc}/asir-contrib/cman-ja.dvi |
|
-$(DVIPS) cman-ja >${INSTALL_doc}/asir-contrib/cman-ja.ps |
|
-cp cman-en.dvi ${INSTALL_doc}/asir-contrib/cman-en.dvi |
|
-$(DVIPS) cman-en >${INSTALL_doc}/asir-contrib/cman-en.ps |
|
gen-dvi-ps: all clean-mk-openxm-asir-contrib-document-dir cman-ja.dvi cman-en.dvi |
|
cman-ja.dvi: ${JASRCS} ${JAAUTO} |
|
-ptex cman-ja.texi |
|
-ptex cman-ja.texi |
|
cman-en.dvi: ${ENSRCS} ${ENAUTO} |
|
-tex cman-en.texi |
|
-tex cman-en.texi |
|
|
|
cman-ja.pdf: cman-ja.dvi |
|
cman-en.pdf: cman-en.dvi |
|
|
|
clean-mk-openxm-asir-contrib-document-dir : |
|
${RM} -rf ${INSTALL_doc}/asir-contrib |
|
${RM} -f ./.done_install ./.done_install_document |
|
mkdir ${INSTALL_doc}/asir-contrib |
|
touch ${INSTALL_doc}/asir-contrib/DO_NOT_EDIT_THIS_DIRECTORY._ALL_FILES_ARE_AUTOMATICDALLY_GENERATED. |
|
|
|
clean: |
|
-${RM} -rf ./.done_install ./.done_install_document config.log config.status autom4te.cache |
|
${RM} -f gentexi ${JAAUTO} ${ENAUTO} gentexi-in.tmp gentexi-out.tmp |
|
${RM} -f *.aux *.cp *.dvi *.fn *.ky *.log *.pg *.toc *.tp *.vr *~ |
|
${RM} -f *.en *.ja |
|
${RM} -rf help-ja help-en tmp-en tmp-ja html-en html-ja |
|