kubo/mk/util.mk
Jakub Sztandera d2cc708650
make(sharness): add plugins as part of sharness build
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
2017-07-12 21:53:59 +02:00

24 lines
431 B
Makefile

# util functions
OS ?= $(shell sh -c 'uname -s 2>/dev/null || echo not')
ifeq ($(OS),Windows_NT)
WINDOWS :=1
?exe :=.exe # windows compat
PATH_SEP :=;
else
?exe :=
PATH_SEP :=:
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