From ccfbb241f4d1a2dbefe684e747c1920da498cbfe Mon Sep 17 00:00:00 2001 From: Gregor Richards Date: Fri, 9 Dec 2016 17:34:44 -0500 Subject: Use git version as library_version --- Makefile | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 3a87d57..e8620ac 100644 --- a/Makefile +++ b/Makefile @@ -39,6 +39,10 @@ TARGET_NAME := snes9x2005_plus else TARGET_NAME := snes9x2005 endif +GIT_VERSION := " $(shell git rev-parse --short HEAD || echo unknown)" +ifneq ($(GIT_VERSION)," unknown") + CFLAGS += -DGIT_VERSION=\"$(GIT_VERSION)\" +endif DEFS := LIBM := -lm -- cgit v1.2.3