]> rtime.felk.cvut.cz Git - pes-rpp/rpp-test-sw.git/blobdiff - Makefile
Include Makefile.var in the release
[pes-rpp/rpp-test-sw.git] / Makefile
index c2d41f622487ff69fe9ca6e61df1195a34bd0605..83dd040457e5fe0cd2f4573092a742a4c5d214d8 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -9,12 +9,13 @@ include rpp-lib/Makefile.var
 all: rpp-test-sw
        $(call rmdir,$(TMP_WORKSPACE))
 
-RELEASE_PREFIX = rpp-test-sw
 include rpp-lib/common.mk
 
+TARGET ?= $(error TARGET variable not defined)
+
 rpp-test-sw: $(TMP_WORKSPACE)
        $(ECLIPSE) -noSplash -data $(TMP_WORKSPACE) -application com.ti.ccstudio.apps.projectImport -ccs.location $(CURDIR)/rpp-test-sw
-       $(ECLIPSE) -noSplash -data $(TMP_WORKSPACE) -application com.ti.ccstudio.apps.projectImport -ccs.location $(CURDIR)/rpp-lib/build/tms570_hdk
+       $(ECLIPSE) -noSplash -data $(TMP_WORKSPACE) -application com.ti.ccstudio.apps.projectImport -ccs.location $(CURDIR)/rpp-lib/build/$(TARGET)
        $(ECLIPSE) -noSplash -data $(TMP_WORKSPACE) -application com.ti.ccstudio.apps.projectBuild -ccs.projects rpp-test-sw
 # Previous commands do not always return non-zero exit code on build failure - invoke make directly to not miss a potential error
        $(MAKE) -C $(CURDIR)/rpp-test-sw/Debug all
@@ -46,10 +47,11 @@ uncrustify:
        git diff --quiet # Check that the tree is clean
        $(UNCRUSTIFY_ALL)
 
+$(eval $(call release_rules,rpp-test-sw))
+
 release: $(RELEASE_BASENAME).zip
 
-RELEASE_TARGET ?= tms570_hdk
-include rpp-lib/build/$(RELEASE_TARGET)/Makefile.config
+RELEASE_TARGET = $(TARGET)
 
 RELEASE_LIB_GIT_FILES = \
        Makefile.var \
@@ -75,4 +77,4 @@ $(RELEASE_BASENAME):: lib
        cp --parents  $(RELEASE_LIB_GEN_FILES:%=rpp-lib/%) $@/
 
 lib:
-       $(MAKE) -C rpp-lib/build/$(RELEASE_TARGET)/Release
+       $(MAKE) -C rpp-lib/build/$(RELEASE_TARGET)/Debug