2015-02-26 15:02:31 +00:00
|
|
|
|
2015-06-22 21:11:08 +00:00
|
|
|
export TRICK_HOST_CPU := $(shell $(TRICK_HOME)/bin/trick-gte TRICK_HOST_CPU)
|
2015-02-26 15:02:31 +00:00
|
|
|
|
|
|
|
# List out sims we want to compile
|
2016-02-23 20:38:49 +00:00
|
|
|
COMPILE_DIRS = \
|
2016-02-23 19:48:59 +00:00
|
|
|
Ball/SIM_ball_L1 \
|
|
|
|
Ball/SIM_ball_L2 \
|
|
|
|
Ball/SIM_ball_L3 \
|
|
|
|
Cannon/SIM_amoeba \
|
|
|
|
Cannon/SIM_cannon_aero \
|
|
|
|
Cannon/SIM_cannon_analytic \
|
|
|
|
Cannon/SIM_cannon_eulercromer \
|
2016-10-27 23:11:15 +00:00
|
|
|
Cannon/SIM_cannon_numeric \
|
2016-02-23 19:48:59 +00:00
|
|
|
Cannon/SIM_cannon_jet \
|
2016-02-23 20:38:49 +00:00
|
|
|
SIM_Ball++_L1 \
|
2015-02-26 15:02:31 +00:00
|
|
|
SIM_satellite \
|
2016-02-23 22:19:30 +00:00
|
|
|
SIM_sun
|
2016-02-23 19:48:59 +00:00
|
|
|
|
|
|
|
#SIM_monte \
|
2015-02-26 15:02:31 +00:00
|
|
|
|
|
|
|
# List out sims we want to run unit tests
|
2016-02-23 20:38:49 +00:00
|
|
|
TEST_DIRS = \
|
2016-02-23 19:48:59 +00:00
|
|
|
Ball/SIM_ball_L1 \
|
|
|
|
Ball/SIM_ball_L2 \
|
|
|
|
Ball/SIM_ball_L3 \
|
|
|
|
Cannon/SIM_amoeba \
|
|
|
|
Cannon/SIM_cannon_aero \
|
|
|
|
Cannon/SIM_cannon_analytic \
|
|
|
|
Cannon/SIM_cannon_eulercromer \
|
2016-10-27 23:11:15 +00:00
|
|
|
Cannon/SIM_cannon_numeric \
|
2016-02-23 19:48:59 +00:00
|
|
|
Cannon/SIM_cannon_jet \
|
2016-02-23 20:38:49 +00:00
|
|
|
SIM_Ball++_L1 \
|
2016-02-23 22:19:30 +00:00
|
|
|
SIM_sun
|
2015-02-26 15:02:31 +00:00
|
|
|
|
2016-02-23 19:48:59 +00:00
|
|
|
#SIM_monte \
|
|
|
|
|
2015-02-26 15:02:31 +00:00
|
|
|
EXECUTABLES = $(addsuffix /T_main_${TRICK_HOST_CPU}_test.exe, $(COMPILE_DIRS))
|
|
|
|
UNIT_TEST_RESULTS = $(addprefix $(TRICK_HOME)/trick_test/, $(addsuffix .xml, $(TEST_DIRS)))
|
|
|
|
|
|
|
|
all:
|
|
|
|
@echo "This makefile is used with Trick's top level 'make test' command"
|
|
|
|
|
2016-02-23 19:48:59 +00:00
|
|
|
test: $(EXECUTABLES) $(UNIT_TEST_RESULTS)
|
2015-02-26 15:02:31 +00:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f $(UNIT_TEST_RESULTS)
|
|
|
|
- for i in $(COMPILE_DIRS) ; do \
|
|
|
|
if [ -f "$$i/"[Mm]"akefile" ] ; then \
|
|
|
|
$(MAKE) -C $$i spotless ; \
|
|
|
|
fi \
|
|
|
|
done
|
|
|
|
|
|
|
|
$(EXECUTABLES):
|
2015-06-22 21:11:08 +00:00
|
|
|
@ cd $(@D) ; ${TRICK_HOME}/bin/trick-CP -t ;
|
2015-02-26 15:02:31 +00:00
|
|
|
|
|
|
|
$(UNIT_TEST_RESULTS): $(TRICK_HOME)/trick_test/%.xml : %/T_main_${TRICK_HOST_CPU}_test.exe
|
|
|
|
@ cd $* ; ./T_main_${TRICK_HOST_CPU}_test.exe RUN_test/unit_test.py
|
|
|
|
|
|
|
|
|