diff options
author | GDR! <gdr@gdr.name> | 2017-11-01 12:04:42 +0100 |
---|---|---|
committer | GDR! <gdr@gdr.name> | 2017-11-01 12:04:42 +0100 |
commit | 44a23bb83ced58f9bf9e4368c507a5af0113ba48 (patch) | |
tree | 8549de995616f07505d0ac0d14393e81f1f92a0b /Makefile | |
parent | c5438fbc05c1f2355c5484a2e67bc52531eb28cd (diff) |
Generate gitversion.h only in git checkouts
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -14,9 +14,10 @@ INCLUDES = $(wildcard *.h) | |||
14 | # Targets | 14 | # Targets |
15 | all: tuntox | 15 | all: tuntox |
16 | 16 | ||
17 | gitversion.h: .git/HEAD .git/index | 17 | gitversion.h: FORCE |
18 | @echo " GEN $@" | 18 | @if [ -f .git/HEAD ] ; then echo " GEN $@"; echo "#define GITVERSION \"$(shell git rev-parse HEAD)\"" > $@; fi |
19 | @echo "#define GITVERSION \"$(shell git rev-parse HEAD)\"" > $@ | 19 | |
20 | FORCE: | ||
20 | 21 | ||
21 | tox_bootstrap.h: | 22 | tox_bootstrap.h: |
22 | python generate_tox_bootstrap.py | 23 | python generate_tox_bootstrap.py |