aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2011-06-28 15:39:51 +0200
committerBjörn Gustavsson <[email protected]>2011-08-08 11:59:11 +0200
commit13cc114325d31626a84fbecbe07bb0f76c3726cf (patch)
treebd871440627ec696493e0553bbe944be58f4739c
parent68ea5a6fd731a8e7a8146fb02666b6f603f56342 (diff)
downloadotp-13cc114325d31626a84fbecbe07bb0f76c3726cf.tar.gz
otp-13cc114325d31626a84fbecbe07bb0f76c3726cf.tar.bz2
otp-13cc114325d31626a84fbecbe07bb0f76c3726cf.zip
eunit: Support parallel make
-rw-r--r--lib/eunit/src/Makefile13
1 files changed, 9 insertions, 4 deletions
diff --git a/lib/eunit/src/Makefile b/lib/eunit/src/Makefile
index 4897c20ec1..bec2fdbe0b 100644
--- a/lib/eunit/src/Makefile
+++ b/lib/eunit/src/Makefile
@@ -26,8 +26,9 @@ INCLUDE=../include
ERL_COMPILE_FLAGS += -pa $(EBIN) -I$(INCLUDE) +warn_unused_vars +nowarn_shadow_vars +warn_unused_import +warn_obsolete_guard
+PARSE_TRANSFORM = eunit_autoexport.erl
+
SOURCES= \
- eunit_autoexport.erl \
eunit_striptests.erl \
eunit.erl \
eunit_tests.erl \
@@ -43,6 +44,8 @@ SOURCES= \
INCLUDE_FILES = eunit.hrl
+PARSE_TRANSFORM_BIN = $(PARSE_TRANSFORM:%.erl=$(EBIN)/%.$(EMULATOR))
+
OBJECTS=$(SOURCES:%.erl=$(EBIN)/%.$(EMULATOR)) $(APP_TARGET) $(APPUP_TARGET)
INCLUDE_DELIVERABLES = $(INCLUDE_FILES:%=$(INCLUDE)/%)
@@ -59,7 +62,7 @@ APPUP_TARGET= $(EBIN)/$(APPUP_FILE)
# Targets
# ----------------------------------------------------
-debug opt: $(OBJECTS)
+debug opt: $(PARSE_TRANSFORM_BIN) $(OBJECTS)
docs:
@@ -86,6 +89,8 @@ realclean: clean
$(EBIN)/%.$(EMULATOR):%.erl
erlc -W $(ERL_COMPILE_FLAGS) -o$(EBIN) $<
+$(OBJECTS): $(PARSE_TRANSFORM_BIN)
+
# ----------------------------------------------------
# Special Build Targets
# ----------------------------------------------------
@@ -103,9 +108,9 @@ include $(ERL_TOP)/make/otp_release_targets.mk
release_spec: opt
$(INSTALL_DIR) $(RELSYSDIR)/ebin
- $(INSTALL_DATA) $(OBJECTS) $(RELSYSDIR)/ebin
+ $(INSTALL_DATA) $(PARSE_TRANSFORM_BIN) $(OBJECTS) $(RELSYSDIR)/ebin
$(INSTALL_DIR) $(RELSYSDIR)/src
- $(INSTALL_DATA) $(SOURCES) $(RELSYSDIR)/src
+ $(INSTALL_DATA) $(PARSE_TRANSFORM) $(SOURCES) $(RELSYSDIR)/src
$(INSTALL_DIR) $(RELSYSDIR)/include
$(INSTALL_DATA) $(INCLUDE_DELIVERABLES) $(RELSYSDIR)/include