util.mk 375 Bytes
Newer Older
1 2 3 4
# util functions
ifeq ($(OS),Windows_NT)
	WINDOWS :=1
	?exe :=.exe # windows compat
5
	PATH_SEP :=;
6 7
else
	?exe :=
8
	PATH_SEP :=:
9 10 11 12 13 14 15 16 17 18 19 20 21 22
endif

space:=
space+=
comma:=,
join-with=$(subst $(space),$1,$(strip $2))

# debug target, prints varaible. Example: `make print-GOFLAGS`
print-%:
	@echo $*=$($*)

# phony target that will mean that recipe is always exectued
ALWAYS:
.PHONY: ALWAYS