- {env: IMPL=logo NO_SELF_HOST=1, services: [docker]} # step4 timeout
- {env: IMPL=lua, services: [docker]}
- {env: IMPL=make NO_SELF_HOST=1, services: [docker]} # step4 timeout
- - {env: IMPL=mal BUILD_IMPL=js NO_SELF_HOST=1, services: [docker]}
+ - {env: IMPL=mal MAL_IMPL=js BUILD_IMPL=js NO_SELF_HOST=1, services: [docker]}
+ - {env: IMPL=mal MAL_IMPL=js-mal BUILD_IMPL=js NO_SELF_HOST=1, services: [docker]}
+ - {env: IMPL=mal MAL_IMPL=nim BUILD_IMPL=nim NO_SELF_HOST=1, services: [docker]}
+ - {env: IMPL=mal MAL_IMPL=nim-mal BUILD_IMPL=nim NO_SELF_HOST=1, services: [docker]}
- {env: IMPL=matlab NO_SELF_HOST_PERF=1, services: [docker]} # Octave, perf timeout
- {env: IMPL=miniMAL NO_SELF_HOST_PERF=1, services: [docker]} # perf timeout
- {env: IMPL=nasm NO_SELF_HOST_PERF=1, services: [docker]} # perf OOM
lc = $(subst A,a,$(subst B,b,$(subst C,c,$(subst D,d,$(subst E,e,$(subst F,f,$(subst G,g,$(subst H,h,$(subst I,i,$(subst J,j,$(subst K,k,$(subst L,l,$(subst M,m,$(subst N,n,$(subst O,o,$(subst P,p,$(subst Q,q,$(subst R,r,$(subst S,s,$(subst T,t,$(subst U,u,$(subst V,v,$(subst W,w,$(subst X,x,$(subst Y,y,$(subst Z,z,$1))))))))))))))))))))))))))
impl_to_image = kanaka/mal-test-$(call lc,$(1))
-actual_impl = $(if $(filter mal,$(1)),$(MAL_IMPL),$(1))
+actual_impl = $(if $(filter mal,$(1)),$(patsubst %-mal,%,$(MAL_IMPL)),$(1))
# Takes impl
# Returns nothing if DOCKERIZE is not set, otherwise returns the
$(ALL_TESTS): $$(call $$(word 2,$$(subst ^, ,$$(@)))_STEP_TO_PROG,$$(word 3,$$(subst ^, ,$$(@))))
@$(foreach impl,$(word 2,$(subst ^, ,$(@))),\
$(foreach step,$(word 3,$(subst ^, ,$(@))),\
- cd $(if $(filter mal,$(impl)),$(MAL_IMPL),$(impl)) && \
+ cd $(call actual_impl,$(impl)) && \
$(foreach test,$(call STEP_TEST_FILES,$(impl),$(step)),\
echo '----------------------------------------------' && \
echo 'Testing $@; step file: $+, test file: $(test)' && \
$(IMPL_PERF):
@echo "----------------------------------------------"; \
$(foreach impl,$(word 2,$(subst ^, ,$(@))),\
- cd $(if $(filter mal,$(impl)),$(MAL_IMPL),$(impl)); \
+ cd $(call actual_impl,$(impl)); \
echo "Performance test for $(impl):"; \
echo 'Running: $(call get_run_prefix,$(impl),stepA) ../$(impl)/run ../tests/perf1.mal'; \
$(call get_run_prefix,$(impl),stepA) ../$(impl)/run ../tests/perf1.mal; \
$(ALL_REPL): $$(call $$(word 2,$$(subst ^, ,$$(@)))_STEP_TO_PROG,$$(word 3,$$(subst ^, ,$$(@))))
@$(foreach impl,$(word 2,$(subst ^, ,$(@))),\
$(foreach step,$(word 3,$(subst ^, ,$(@))),\
- cd $(if $(filter mal,$(impl)),$(MAL_IMPL),$(impl)); \
+ cd $(call actual_impl,$(impl)); \
echo 'REPL implementation $(impl), step file: $+'; \
echo 'Running: $(call get_run_prefix,$(impl),$(step)) ../$(impl)/run $(RUN_ARGS)'; \
$(call get_run_prefix,$(impl),$(step)) ../$(impl)/run $(RUN_ARGS);))