Select Git revision
target-update-makefiles.mk

Volker Schukai authored
target-update-makefiles.mk 1.10 KiB
#############################################################################################
#############################################################################################
##
## INIT-TARGETS
##
#############################################################################################
#############################################################################################
ifeq ($(GIT),)
$(error $(ERRORMARKER) Git is not defined, check your Makefile if git.mk is included)
endif
# @see .PHONY https://www.gnu.org/software/make/manual/html_node/Phony-Targets.html#Phony-Targets
.PHONY: update-makefiles
ifeq ($(QUIET),)
_COPYVERBOSE = -v
endif
## update standard makefiles
update-makefiles:
$(ECHOMARKER) "update standard makefiles"
$(QUIET) $(eval TEMPD := $(shell mktemp -d))
$(QUIET) $(GIT) clone --quiet --depth=1 https://gitlab.schukai.com/schukai/utilities/makefile.git/ "$(TEMPD)"
$(QUIET) $(CP) -r $(_COPYVERBOSE) $(TEMPD)/makefiles/* $(MAKEFILE_IMPORT_PATH)
$(QUIET) $(CP) -r $(_COPYVERBOSE) $(TEMPD)/Makefile $(PROJECT_ROOT)Makefile.example
$(QUIET) $(RM) -rf $(TEMPD)