dynare/tests/Makefile.in

87 lines
2.1 KiB
Makefile

OCTAVE = @OCTAVE@
DYNARE_ROOT = @abs_top_srcdir@/matlab
DYNARE_VERSION = @PACKAGE_VERSION@
# Under Octave we only test a subset of MOD files, because of missing features (models with unit roots, reading Excel files)
OCTAVE_MODS = \
ramst.mod \
ramst_a.mod \
example1.mod \
t_sgu_ex1.mod \
ramsey.mod \
arima/mod1.mod \
arima/mod1a.mod \
arima/mod2.mod \
arima/mod2c.mod \
fs2000/fs2000.mod \
homotopy/homotopy1_test.mod \
homotopy/homotopy2_test.mod \
homotopy/homotopy3_test.mod \
bvar_a_la_sims/bvar_standalone.mod \
bvar_a_la_sims/bvar_and_dsge.mod
MODS = $(OCTAVE_MODS) \
arima/mod1b.mod \
arima/mod1c.mod \
arima/mod2a.mod \
arima/mod2b.mod \
fs2000/fs2000a.mod
check: check-octave check-matlab
.PHONY: check
check-octave: $(OCTAVE_MODS)
ifdef OCTAVE
@set -e; \
for modfile in $(OCTAVE_MODS); do \
GNUTERM=dumb $(OCTAVE) --norc --silent --no-history run_test_octave.m $$modfile $(DYNARE_ROOT) $(DYNARE_VERSION); \
done
endif
.PHONY: check-octave
check-matlab: $(MODS)
# MATLAB stuff to be added here
.PHONY: check-matlab
clean:
# Files generated by the preprocessor
rm -f $(patsubst %.mod, %.m, $(MODS)) \
$(patsubst %.mod, %_static.m, $(MODS)) \
$(patsubst %.mod, %_objective_static.m, $(MODS)) \
$(patsubst %.mod, %_dynamic.m, $(MODS))
# Results
rm -f $(patsubst %.mod, %_results.mat, $(MODS)) \
$(patsubst %.mod, %_mode.mat, $(MODS)) \
$(patsubst %.mod, %_mh_mode.mat, $(MODS)) \
$(patsubst %.mod, %_mean.mat, $(MODS)) \
$(patsubst %.mod, %_pindx.mat, $(MODS)) \
$(patsubst %.mod, %_params.mat, $(MODS)) \
$(patsubst %.mod, %.log, $(MODS))
rm -rf $(patsubst %.mod, %, $(MODS))
# Graphics
rm -f $(patsubst %.mod, %*.pdf, $(MODS)) \
$(patsubst %.mod, %*.eps, $(MODS)) \
$(patsubst %.mod, %*.fig, $(MODS))
# Files generated by csminwel.m
rm -f $(shell find -name g1.mat) \
$(shell find -name g2.mat) \
$(shell find -name g3.mat) \
$(shell find -name H.dat)
# Generated data files
rm -f arima/data1.m arima/data2.m
# Backup files
rm -f $(shell find -name '*~')
.PHONY: clean
# Recreate Makefile when necessary
Makefile: Makefile.in ../config.status
cd .. && ./config.status