aboutsummaryrefslogtreecommitdiffstats
path: root/lib/compiler/test/Makefile
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2016-10-07 12:46:50 +0200
committerBjörn Gustavsson <[email protected]>2016-11-18 11:58:34 +0100
commit506f0982825f032b404425e777010459e974596f (patch)
tree10b8b64583301baa90d364f071bf40d29b922298 /lib/compiler/test/Makefile
parent132d61e6f075f8e85da268e88953980c2f348987 (diff)
downloadotp-506f0982825f032b404425e777010459e974596f.tar.gz
otp-506f0982825f032b404425e777010459e974596f.tar.bz2
otp-506f0982825f032b404425e777010459e974596f.zip
Add test using LFE-generated Core Erlang modules
Ensure that correct (not necessarily optimal) code is generated for Core Erlang code not originating from v3_core.
Diffstat (limited to 'lib/compiler/test/Makefile')
-rw-r--r--lib/compiler/test/Makefile14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/compiler/test/Makefile b/lib/compiler/test/Makefile
index f2c68505fc..e338dbb4e3 100644
--- a/lib/compiler/test/Makefile
+++ b/lib/compiler/test/Makefile
@@ -93,6 +93,10 @@ INLINE= \
receive \
record
+CORE_MODULES = \
+ lfe_andor_SUITE \
+ lfe_guard_SUITE
+
NO_OPT_MODULES= $(NO_OPT:%=%_no_opt_SUITE)
NO_OPT_ERL_FILES= $(NO_OPT_MODULES:%=%.erl)
POST_OPT_MODULES= $(NO_OPT:%=%_post_opt_SUITE)
@@ -101,6 +105,8 @@ INLINE_MODULES= $(INLINE:%=%_inline_SUITE)
INLINE_ERL_FILES= $(INLINE_MODULES:%=%.erl)
ERL_FILES= $(MODULES:%=%.erl)
+CORE_FILES= $(CORE_MODULES:%=%.core)
+ERL_DUMMY_FILES= $(CORE_MODULES:%=%.erl)
##TARGET_FILES= $(MODULES:%=$(EBIN)/%.$(EMULATOR))
##INSTALL_PROGS= $(TARGET_FILES)
@@ -134,6 +140,8 @@ make_emakefile: $(NO_OPT_ERL_FILES) $(POST_OPT_ERL_FILES) $(INLINE_ERL_FILES)
-o$(EBIN) $(POST_OPT_MODULES) >> $(EMAKEFILE)
$(ERL_TOP)/make/make_emakefile +inline $(ERL_COMPILE_FLAGS) \
-o$(EBIN) $(INLINE_MODULES) >> $(EMAKEFILE)
+ $(ERL_TOP)/make/make_emakefile +from_core $(ERL_COMPILE_FLAGS) \
+ -o$(EBIN) $(CORE_MODULES) >> $(EMAKEFILE)
tests debug opt: make_emakefile
erl $(ERL_MAKE_FLAGS) -make
@@ -171,6 +179,12 @@ release_tests_spec: make_emakefile
$(EMAKEFILE) $(ERL_FILES) "$(RELSYSDIR)"
$(INSTALL_DATA) $(NO_OPT_ERL_FILES) $(POST_OPT_ERL_FILES) \
$(INLINE_ERL_FILES) "$(RELSYSDIR)"
+ $(INSTALL_DATA) $(CORE_FILES) "$(RELSYSDIR)"
+ for file in $(ERL_DUMMY_FILES); do \
+ module=`basename $$file .erl`; \
+ echo "-module($$module). %% dummy .erl file" >$$file; \
+ done
+ $(INSTALL_DATA) $(ERL_DUMMY_FILES) "$(RELSYSDIR)"
chmod -R u+w "$(RELSYSDIR)"
@tar cf - *_SUITE_data | (cd "$(RELSYSDIR)"; tar xf -)