1 # Common GNU Make definitions useful for multiple Makefiles
3 ECLIPSE=$(foreach file,\
4 /opt/ti/ccsv5/eclipse/eclipse \
5 C:/ti/ccsv5/eclipse/eclipsec.exe,\
6 $(if $(wildcard $(file)),$(file)))
8 ifeq ($(OS),Windows_NT)
9 TMP_WORKSPACE=$(TEMP)/_workspace
11 TMP_WORKSPACE:=$(shell mktemp --dry-run --tmpdir -d rpp-test-sw-workspace.XXXXXXXXXX)
15 ifeq ($(OS),Windows_NT)
16 pathconv=$(subst /,\,$1)
17 mkdir=-mkdir $(subst /,\,$1)
18 rm=-del /Q $(call pathconv,$1)
19 rmdir=-rmdir /S /Q $(call pathconv,$1)
20 cp=copy $(subst /,\,$1) $(subst /,\,$2)
30 RELEASE_PREFIX ?= prefix
31 ifneq ($(OS),Windows_NT)
32 RELEASE_VERSION := $(shell git describe --always $(RELEASE_COMMIT)|sed -e "s/^[-a-zA-Z_]*//")
34 RELEASE_BASENAME = $(RELEASE_PREFIX)-$(RELEASE_VERSION)
36 .PHONY: $(RELEASE_BASENAME).zip
38 $(RELEASE_BASENAME).zip:
39 rm -rf $@ $(RELEASE_BASENAME)
40 $(MAKE) $(RELEASE_BASENAME)
41 zip -r $@ $(RELEASE_BASENAME)
44 git archive --worktree-attributes --prefix=$@/ $(RELEASE_COMMIT) | tar xf -