Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Johannes Pfeifer
dynare
Commits
0f28974c
Verified
Commit
0f28974c
authored
Mar 22, 2019
by
Sébastien Villemot
Browse files
Provisions for MATLAB R2019a
In particular, use the new "-batch" option for running the testsuite.
parent
4f6a8a95
Changes
5
Hide whitespace changes
Inline
Side-by-side
configure.ac
View file @
0f28974c
...
...
@@ -137,13 +137,7 @@ AC_ARG_ENABLE([matlab], AS_HELP_STRING([--disable-matlab], [disable compilation
if test "x$enable_matlab" = "xyes"; then
AC_CONFIG_SUBDIRS([mex/build/matlab])
AX_MATLAB
AX_MATLAB_ARCH
if test "${MATLAB_ARCH}" = win32 -o "${MATLAB_ARCH}" = win64; then
MATLAB_BATCH_OPTIONS='-nosplash -automation -wait -sd "$(CURDIR)"'
else
MATLAB_BATCH_OPTIONS='-nosplash -nodisplay'
fi
AC_SUBST([MATLAB_BATCH_OPTIONS])
AX_MATLAB_BATCH_OPTIONS
fi
AM_CONDITIONAL([ENABLE_MATLAB], [test "x$enable_matlab" = "xyes"])
AM_CONDITIONAL([HAVE_CMD_LINE_MATLAB], [test "x$ax_enable_matlab" = "xyes" -a "x$have_windows" = "x"])
...
...
m4/ax_matlab_batch_options.m4
0 → 100644
View file @
0f28974c
dnl Copyright (C) 2019 Dynare Team
dnl
dnl This file is part of Dynare.
dnl
dnl Dynare is free software: you can redistribute it and/or modify
dnl it under the terms of the GNU General Public License as published by
dnl the Free Software Foundation, either version 3 of the License, or
dnl (at your option) any later version.
dnl
dnl Dynare is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
dnl GNU General Public License for more details.
dnl
dnl You should have received a copy of the GNU General Public License
dnl along with Dynare. If not, see <http://www.gnu.org/licenses/>.
AC_DEFUN([AX_MATLAB_BATCH_OPTIONS],
[dnl
AC_REQUIRE([AX_MATLAB])
AC_REQUIRE([AX_MATLAB_ARCH])
AC_REQUIRE([AX_MATLAB_VERSION])
AX_COMPARE_VERSION([$MATLAB_VERSION], [ge], [9.6],
[MATLAB_BATCH_OPTIONS='-batch'],
[
if test "${MATLAB_ARCH}" = win32 -o "${MATLAB_ARCH}" = win64; then
MATLAB_BATCH_OPTIONS='-nosplash -automation -wait -sd "$(CURDIR)" -r'
else
MATLAB_BATCH_OPTIONS='-nosplash -nodisplay -r'
fi
])
AC_SUBST([MATLAB_BATCH_OPTIONS])
])
m4/ax_matlab_version.m4
View file @
0f28974c
...
...
@@ -22,6 +22,9 @@ AC_REQUIRE([AX_MATLAB])
AC_MSG_CHECKING([for MATLAB version])
if test "x$MATLAB_VERSION" != "x"; then
case $MATLAB_VERSION in
*2019a | *2019A)
MATLAB_VERSION="9.6"
;;
*2018b | *2018B)
MATLAB_VERSION="9.5"
;;
...
...
tests/Makefile.am
View file @
0f28974c
...
...
@@ -882,7 +882,7 @@ check-octave: $(O_XFAIL_TRS_FILES) $(O_TRS_FILES)
%.m.trs %.m.log
:
%.mod
@
echo
"
`
tput bold
``
tput setaf 8
`
MATLAB:
$(CURDIR)
/
$*
...
`
tput sgr0
`
"
@
DYNARE_VERSION
=
"
$(PACKAGE_VERSION)
"
TOP_TEST_DIR
=
"
$(CURDIR)
"
FILESTEM
=
"
$*
"
\
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
-r
run_test_matlab
>
$*
.m.log 2> /dev/null
||
\
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
run_test_matlab
>
$*
.m.log 2> /dev/null
||
\
printf
":test-result: FAIL
\n
:number-tests: 1
\n
:number-failed-tests: 1
\n
:list-of-failed-tests:
$*
.mod
\n
:elapsed-time: 0.0
\n
"
>
$*
.m.trs
@
if
test
-z
"
$(
filter
$*
.m.trs,
$(M_XFAIL_TRS_FILES)
)
"
;
then
pass_color
=
2
;
fail_color
=
1
;
else
pass_color
=
1
;
fail_color
=
2
;
fi
;
\
if
grep
-q
":test-result: PASS"
$*
.m.trs
;
then
\
...
...
@@ -897,7 +897,7 @@ check-octave: $(O_XFAIL_TRS_FILES) $(O_TRS_FILES)
%.m.trs %.m.log
:
%.m
@
echo
"
`
tput bold
``
tput setaf 8
`
MATLAB:
$(CURDIR)
/
$*
...
`
tput sgr0
`
"
@
DYNARE_VERSION
=
"
$(PACKAGE_VERSION)
"
TOP_TEST_DIR
=
"
$(CURDIR)
"
\
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
-r
$*
>
$*
.m.log 2> /dev/null
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
$*
>
$*
.m.log 2> /dev/null
@
echo
"
`
tput bold
``
tput setaf 8
`
MATLAB:
$(CURDIR)
/
$*
Done!
`
tput sgr0
`
"
%.o.trs %.o.log
:
%.mod
...
...
@@ -925,7 +925,7 @@ check-octave: $(O_XFAIL_TRS_FILES) $(O_TRS_FILES)
%.m.tls
:
%.m
@
echo
"
`
tput bold
``
tput setaf 8
`
MATLAB:
$(CURDIR)
/
$*
...
`
tput sgr0
`
"
@
TOP_TEST_DIR
=
"
$(CURDIR)
"
FILESTEM
=
"
$*
"
\
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
-r
run_m_script
>
/dev/null 2>&1
$(MATLAB)
/bin/matlab
$(MATLAB_BATCH_OPTIONS)
run_m_script
>
/dev/null 2>&1
@
touch
$*
.m.tls
@
echo
"
`
tput bold
`
MATLAB
`
tput setaf 8
`
:
$(CURDIR)
/
$*
Done!
`
tput sgr0
`
"
...
...
windows/dynare.nsi
View file @
0f28974c
...
...
@@ -98,9 +98,9 @@ Section "MEX files for MATLAB 64-bit, version 7.9 to 9.3 (R2009b to R2017b)"
File ..\mex\matlab\win64-7.9-9.3\*.mexw64
SectionEnd
Section "MEX files for MATLAB 64-bit, version 9.4 to 9.5 (R2018a to R201
8b
)"
SetOutPath $INSTDIR\mex\matlab\win64-9.4-9.
5
File ..\mex\matlab\win64-9.4-9.
5
\*.mexw64
Section "MEX files for MATLAB 64-bit, version 9.4 to 9.5 (R2018a to R201
9a
)"
SetOutPath $INSTDIR\mex\matlab\win64-9.4-9.
6
File ..\mex\matlab\win64-9.4-9.
6
\*.mexw64
SectionEnd
SectionGroupEnd
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment