summaryrefslogtreecommitdiffstats
path: root/subsurface.pro
diff options
context:
space:
mode:
authorGravatar Lubomir I. Ivanov <neolit123@gmail.com>2015-01-30 18:56:12 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-02-15 06:19:33 -0800
commitf6dbed1fc6c71251e1937cb1b63e96ff7a8251c3 (patch)
tree709da15b9ead9d44198953765e06409355b43d56 /subsurface.pro
parent27b4d10f91e4cab61756747d5b8d0f17a29d3e7a (diff)
downloadsubsurface-f6dbed1fc6c71251e1937cb1b63e96ff7a8251c3.tar.gz
qmake: use a dedicated build script to generate ssrf-version.h
- added ./scripts/write-version - subsurface-gen-version.pri is much simpler now - .git/HEAD is no longer used explicitly in .pro/.pri files - the version_h rule is called on each 'make' invocation but recompilation will occur only if ssrf-version.h is updated by ./scripts/write-version - qmake now depends on the existence of ssrf-version.h so it creates an empty one on Makefile generation so that a warning is not shown Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface.pro')
-rw-r--r--subsurface.pro4
1 files changed, 4 insertions, 0 deletions
diff --git a/subsurface.pro b/subsurface.pro
index 7a00d7492..a34bc091a 100644
--- a/subsurface.pro
+++ b/subsurface.pro
@@ -20,8 +20,12 @@ else: TARGET = subsurface
QMAKE_CLEAN += $$TARGET
VERSION = 4.4
+VERSION_FILE = $$OUT_PWD/ssrf-version.h
+# create a blank VERSION_FILE if missing
+system(cat $$VERSION_FILE > /dev/null 2>&1 || touch $$VERSION_FILE)
HEADERS = \
+ $$VERSION_FILE \
cochran.h \
color.h \
deco.h \