mirror of
https://github.com/simh/simh.git
synced 2026-01-13 23:35:57 +00:00
makefile: Properly detect building with uncommitted changes
This commit is contained in:
parent
076c1ef094
commit
73be1953ee
8
makefile
8
makefile
@ -290,10 +290,10 @@ ifeq (${WIN32},) #*nix Environments (&& cygwin)
|
||||
else
|
||||
NEED_COMMIT_ID = need-commit-id
|
||||
endif
|
||||
ifeq (need-commit-id,$(NEED_COMMIT_ID))
|
||||
ifneq (,$(shell git update-index --refresh --))
|
||||
GIT_EXTRA_FILES=+uncommitted-changes
|
||||
endif
|
||||
ifneq (,$(shell git update-index --refresh --))
|
||||
GIT_EXTRA_FILES=+uncommitted-changes
|
||||
endif
|
||||
ifneq (,$(or $(NEED_COMMIT_ID),$(GIT_EXTRA_FILES)))
|
||||
isodate=$(shell git log -1 --pretty="%ai"|sed -e 's/ /T/'|sed -e 's/ //')
|
||||
$(shell git log -1 --pretty="SIM_GIT_COMMIT_ID %H$(GIT_EXTRA_FILES)%nSIM_GIT_COMMIT_TIME $(isodate)" >.git-commit-id)
|
||||
endif
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user