Commit Graph

145 Commits (7bf0395a2708a524725c0c25a3cefe5a5f54a8a5)

Author SHA1 Message Date
Johannes Pfeifer 4512e85cb2 Restore outputs erroneously removed in 735bd66d 2023-12-18 17:07:01 +01:00
Stéphane Adjemian (Ryûk) 4982ce06b4
Remove unnecessary square brackets. 2023-12-18 10:49:49 +01:00
Stéphane Adjemian (Ryûk) 735bd66d4d
Remove unused output arguments. 2023-12-18 07:48:27 +01:00
Sébastien Villemot 1d5a442fe5
Bump minimal required version of Octave to 7.1.0
Incidentally, this means that the JSONlab submodule is no longer needed, so it
is removed in the present commit.

Closes: #1907
2023-11-22 17:46:13 +01:00
Sébastien Villemot 7f58e819c6
Bump minimal required version of MATLAB to R2018b
Ref. #1907
2023-11-22 16:00:04 +01:00
Johannes Pfeifer 643face6ed bug: do not remove +subfolder with fast option
Otherwise, expected files are not present
2023-10-20 15:42:44 +02:00
Johannes Pfeifer fb8ff758f9 By default display preprocessor output line by line instead of only at the end
Allows judging how long individual steps take for big models
2023-10-20 15:42:05 +02:00
Sébastien Villemot d77561e241
Update comment following the switch to Meson
[skip ci]
2023-10-03 15:02:07 +02:00
Stéphane Adjemian (Ryûk) 8d7a5e69d7
Return Computing and preprocessing time. 2023-09-22 22:29:42 +02:00
Sébastien Villemot 16f921ed62
Add Meson build system
Mostly working. The testsuite remains to be done.

In particular, windows/deps/mkoctfile64 is modified to print its version number
on stdout instead of stderr. This is what the standard mkoctfile does, and it
allows easier capture of the output from Meson.
2023-09-04 18:04:00 +02:00
Sébastien Villemot 2c44923384
No longer turn off output pagination
The “more off” command is incompatible with MATLAB Online.

Moreover, output pagination is disabled by default on MATLAB and on
Octave (since version 4 for the latter), so in most cases that command would do
nothing.

Incidentally, this allows users to enable output pagination should they want
to.

[skip ci]
2023-02-08 11:02:29 -05:00
Sébastien Villemot b343f0231d
Ensure that generated sparse MEX files are unloaded before the preprocessor is run
This workaround already existed for the legacy representation.
2023-01-10 16:07:29 +01:00
Sébastien Villemot 10af04c6d8
Use Unicode copyright symbol (in UTF-8 encoding) in all source files
It is now supported by the MATLAB editor (as of R2022a).

The old ASCII notation is left in some files that we copy as-is from other
sources (e.g. in the contrib/ and m4/ subdirectories).

The particles submodule is not updated at this point, because it is in an
inconsistent state.

[skip ci]
2022-04-13 14:54:25 +02:00
Sébastien Villemot 766fff88f6
Use secure URL for link to GNU licenses 2021-06-09 17:35:05 +02:00
Stéphane Adjemian (Charybdis) 3e7cd877d3
Fix error message consistently with 2743ca8fd.
[skip ci]
2021-05-26 19:11:01 +02:00
Stéphane Adjemian (Charybdis) 2743ca8fdb
Fix workspace if dynare is called from a function. 2021-05-26 19:07:44 +02:00
Johannes Pfeifer cc045caa6f
loglinear: Take care of non-logged lagged/leaded exogenous variables
Closes: #1783
2021-05-11 17:47:25 +02:00
Johannes Pfeifer 5a2fbe2f89 dynare.m: remove non-working line feed 2021-05-11 14:24:02 +02:00
Johannes Pfeifer f43ee91ed8 Filter out "Dot indexing is not supported for variables of this type." error if variable conflicts with namespace 2021-05-06 10:59:19 +02:00
Sébastien Villemot 47477e152a
Bump minimal Octave version to 6.2.0 2021-03-12 16:21:57 +01:00
Sébastien Villemot 8e7d0d2c5d
Preprocessor binary renamed and moved, various other improvements to make install rules
– preprocessor binary renamed to dynare-preprocessor
— the preprocessor binary is now installed under a preprocessor/ top-level directory
— a backward-compatibility symlink is still provided under
  matlab/preprocessor64/dynare_m
— the make install rule now install PDF and HTML documentation when those have
  been built

Closes: #1728
2021-01-06 18:17:20 +01:00
Sébastien Villemot 25d5352350
Include Dynare version and input arguments into log file
The log file is now started from dynare.m.

Closes: #1743
2021-01-06 14:29:37 +01:00
Sébastien Villemot 4d22c4c0c0
Drop 32-bit binaries from Windows package
Closes: #1713
2020-07-17 12:52:58 +02:00
Sébastien Villemot 75211742b8
MATLAB+Windows: workaround to allow the preprocessor to delete the +modfile folder
For an instance of this bug, see
https://forum.dynare.org/t/issue-with-dynare-preprocessor-4-6-1/15448/1
2020-06-23 18:14:12 +02:00
Sébastien Villemot 81f3e81f3e
Remove obsolete workaround for Octave 2020-06-23 17:59:33 +02:00
Sébastien Villemot 6e0f104d7e
Bump minimal MATLAB version to R2014a
Ref. #1713
2020-04-07 16:32:32 +02:00
Sébastien Villemot ae59f4dcb2
Further improvements to parsing of arguments on the MATLAB command-line
Under GNU/Linux and macOS, double-quote arguments before passing them to the
shell. In particular, this allows passing single-quotes within those arguments.

We therefore have to escape the four characters that are interpreted within
double-quoted strings in POSIX shells: \, ", $ and `

On Windows, also systematically escape the backslashes.

Also move display of arguments before escaping, so that it remains readable.

Ref. #1696
2020-02-10 18:24:51 +01:00
Houtan Bastani d527096e61
simplify parsing of MATLAB command line arguments
closes #1696

includes preprocessor changes
- Removed prefixing of doubles between -1 and 1 with 0.
- Fixed bug introduced in 985d742.
- macro processor: simplify handling of `@#define`
2020-01-29 14:56:52 +01:00
Sébastien Villemot d3e90a8dbf
Fix the handling of options nopreprocessoroutput, onlyjson and onlymacro when they appear at the top of the .mod file
The nopathchange is still not supported in this context, so document it.

Also recommend the whitespace-separated syntax instead of the comma-separated
syntax, since the latter is inconsistent with the way options are passed on the
command-line.

Closes: #1667
2020-01-23 18:58:08 +01:00
Sébastien Villemot 9f51b2508a
Disable spurious warnings as early as possible
This is necessary for Octave under Windows, to avoid a warning about isdir()
triggered by user_has_octave_forge_package.m.
2020-01-21 18:39:33 +01:00
Sébastien Villemot 4e314a529b
Bump minimal required Octave version to 4.4 2020-01-06 18:29:47 +01:00
Sébastien Villemot 49dc997073
Global reindentation of MATLAB code (excluding submodules)
Also convert to Unix end-of-lines, and remove trailing whitespaces.
2019-12-20 16:30:27 +01:00
Houtan Bastani dec7d4fdb4
dynare.m: simplify code 2019-12-06 12:01:58 +01:00
Houtan Bastani 3a223e9c08
fix uncommon bug in parsing dynare command line options
previously, `nopathchange` and `nopreprocessoroutput` were set even if they were values instead of option names.

`nopathchange` would further remove all options that contained `'nopathchange'`

e.g. `dynare example1.mod savemacro=nopathchange` would erroneously set `nopathchange` to true and would delete the `savemacro` option altogether

In the fix, just check that the match starts in position 1 as, if the argument passed is longer than the matching pattern (e.g. nopathchangee), the preprocessor will stop processing with a usage error
2019-12-06 12:01:57 +01:00
Houtan Bastani 8b86f8a25b
ignore unused output variable 2019-10-09 14:53:33 +02:00
Sébastien Villemot f44bb38c72
More capitalization fixes and cosmetics
[skip ci]
2019-10-03 16:21:15 +02:00
Houtan Bastani 53ce6222c2
remove unused variable in dynare_config 2019-09-05 11:48:19 +02:00
Sébastien Villemot e872f08cc5
Improve display of preprocessor arguments under Octave 2019-05-20 18:53:51 +02:00
Sébastien Villemot f363c3da6b
Restore behavior of 'nolog' option
The option had been broken by 0e77815ece.

This option cannot be entirely handled at the preprocessor level, since the
main log file is created at the MATLAB/Octave level. Handle it via a dedicated
regular expression.
2018-12-20 17:10:22 +01:00
Sébastien Villemot 0e77815ece
Options list at the top of the mod-file now parsed by the preprocessor
Closes #1630
2018-12-19 16:15:48 +01:00
Sébastien Villemot 18faa9733c
Further updates related to minimal MATLAB version bump 2018-11-13 18:29:20 +01:00
Sébastien Villemot 7a75872f72
Modernization: use tilde (~) syntax for ignored output arguments 2018-11-13 18:02:09 +01:00
Sébastien Villemot 736d43c4e6
Bump minimal MATLAB version requirement to 7.9 (R2009b) 2018-11-13 15:59:16 +01:00
Sébastien Villemot 096936be9c
The preprocessor now compiles the MEX when use_dll is specified
Update documentation accordingly (except on macOS where the solution has not
yet been implemented).

Also include MinGW in the Windows installer.
2018-10-29 14:41:34 +01:00
Sébastien Villemot b2c554623f Various fixes related to the new layout of generated files 2018-06-28 18:14:40 +02:00
Sébastien Villemot a1b8bd39b2 Move the location of various generated files on the filesystem
- M and MEX files are now under +${MODELNAME}/
- bytecode, C source and JSON now under ${MODELNAME}/model/
2018-06-27 17:03:39 +02:00
Sébastien Villemot a71e0ebee4 Add a compile-time check for MATLAB version, as we already do for Octave 2018-06-06 14:31:25 +02:00
Sébastien Villemot 88e89dfb21 Refactor test for Octave version
Distinguish between a minimal version required (from a source code perspective,
applicable on all platforms) and an exact version requirement (from a binary
package perspective, in practice used only for our Windows package).
2018-06-06 14:27:53 +02:00
Sébastien Villemot 0b2828af8a Fix typo 2018-06-05 17:27:22 +02:00
Sébastien Villemot e8ade6a187 Fix display of Dynare command arguments 2018-06-05 17:27:03 +02:00