]> rtime.felk.cvut.cz Git - jenkicar/rpp-simulink.git/blob - Makefile
Include ccxml in simulink release
[jenkicar/rpp-simulink.git] / Makefile
1 RELEASE_PREFIX = rpp-simulink
2
3 include rpp/lib/Makefile.var
4 include rpp/lib/common.mk
5
6 release: $(RELEASE_BASENAME).zip
7         cp rpp/lib/$(shell make -C rpp/lib --silent print-release-basename).zip .
8         $(MAKE) -C doc/test-sw release
9         cp doc/test-sw/$(shell make -C doc/test-sw --silent print-release-basename).zip .
10         cp doc/rpp_simulink.pdf rpp_simulink-$(RELEASE_VERSION).pdf
11
12 RELEASE_TARGET ?= tms570_hdk
13 include rpp/lib/build/$(RELEASE_TARGET)/Makefile.config
14
15 RELEASE_LIB_GIT_FILES = \
16         Makefile.var \
17         build/$(RELEASE_TARGET)/$(TARGET_CCXML) \
18         build/$(RELEASE_TARGET)/$(TARGET_LDCMD) \
19         build/Makefile.rules \
20         build/Makefile.rules.arm \
21         os/$(rpp_lib_OS)/include/ \
22         rpp/include/
23
24 ifneq ($(filter lwip/src/include,$(rpp_lib_INCLUDES)),)
25 RELEASE_LIB_GIT_FILES += lwip/src/include/
26 endif
27
28 RELEASE_LIB_GEN_FILES = Makefile.config rpp-lib.lib
29
30 $(RELEASE_BASENAME):: LIB_RELEASE_BASENAME:=$(shell make -C rpp/lib --silent print-release-basename)
31 $(RELEASE_BASENAME):: lib
32 # Copy library headers and binaries
33         git --git-dir=rpp/lib/.git archive --worktree-attributes --prefix=$@/rpp/lib/ HEAD $(RELEASE_LIB_GIT_FILES) | tar xf -
34         cp --parents  $(RELEASE_LIB_GEN_FILES:%=rpp/lib/%) $@/
35 # Compile and include the PDF documentation
36         $(MAKE) -C doc
37         mkdir -p $@/doc
38         cp doc/rpp_simulink.pdf $@/doc
39
40 lib:
41         $(MAKE) -C rpp/lib/build/$(RELEASE_TARGET)/Release # Compile the lib
42         $(MAKE) -C rpp/lib release # Create release zip and directory