aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorGregor Richards2016-12-09 17:34:44 -0500
committerGregor Richards2016-12-09 17:34:44 -0500
commitccfbb241f4d1a2dbefe684e747c1920da498cbfe (patch)
tree4eda9f76f094d1253f9782c9dd6cd8a22b01228d /Makefile
parentfe3ecfc7e1207ec895bfc939447a9916b42af561 (diff)
downloadsnesemu-ccfbb241f4d1a2dbefe684e747c1920da498cbfe.tar.gz
snesemu-ccfbb241f4d1a2dbefe684e747c1920da498cbfe.tar.bz2
snesemu-ccfbb241f4d1a2dbefe684e747c1920da498cbfe.zip
Use git version as library_version
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
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