Added M2HTML to the build system

time-shift
Sébastien Villemot 2010-11-08 13:08:15 +01:00
parent 31b734e9b3
commit 7fd77a87dd
3 changed files with 26 additions and 0 deletions

2
.gitignore vendored
View File

@ -64,6 +64,8 @@ ylwrap
!/doc/parallel/quest_*.pdf
!/doc/parallel/RWMH_quest1_*.pdf
!/doc/parallel/waitbars*.pdf
doc/m2html
mex/build/matlab/run_m2html.m
# Preprocessor
/preprocessor/dynare_m

View File

@ -6,6 +6,19 @@ SUBDIRS = mjdgges kronecker bytecode libdynare++ gensylv k_order_perturbation dy
if HAVE_GSL
SUBDIRS += swz
endif
if HAVE_M2HTML
html-local:
echo "addpath ${M2HTML}" > run_m2html.m
echo "cd ../../.." >> run_m2html.m
echo "m2html('mFiles', 'matlab', 'htmlDir', 'doc/m2html', 'recursive', 'on', 'globalHypertextLinks', 'on')" >> run_m2html.m
echo "quit" >> run_m2html.m
$(MATLAB)/bin/matlab -r run_m2html # Not using the -nodisplay option, because with m2html it confuses the terminal (need to do a "reset")
clean-local:
rm -f run_m2html.m
rm -rf ../../../doc/m2html
endif
endif
EXTRA_DIST = mex.def mexFunction-MacOSX.map

View File

@ -99,6 +99,16 @@ AC_ARG_ENABLE([openmp], AS_HELP_STRING([--enable-openmp], [use OpenMP for parall
fi
])
AC_ARG_WITH([m2html], AS_HELP_STRING([--with-m2html=DIR], [specify installation directory of M2HTML]), [
M2HTML=$withval
BUILD_M2HTML=yes
], [
M2HTML=
BUILD_M2HTML=no
])
AC_SUBST([M2HTML])
AM_CONDITIONAL([HAVE_M2HTML], [test "x$M2HTML" != "x"])
AC_MSG_NOTICE([
Dynare is now configured for building the following components...
@ -106,6 +116,7 @@ Dynare is now configured for building the following components...
Binaries (with "make"):
MEX files for MATLAB (except SWZ): $BUILD_MEX_MATLAB
SWZ MEX files for MATLAB: $BUILD_SWZ_MEX_MATLAB
M2HTML documentation: $BUILD_M2HTML
])