I’m trying to add git-tags to our program, using something like:
DEFINES += GITHASH=$(shell git describe)
in the project file. This method was suggested elsewhere (http://qt-project.org/forums/viewthread/34635), because it adds the command to the Makefile, therefore not requiring a re-run of qmake every time. However, its not working for us. The statement ends up in the Makefile as:
-DGITHASH=$(shell git describe)
but seems to be missing some quotation marks / slashes which (with my limited experience with Qt) I can’t seem to add. Can anyone point me in the right direction of the correct syntax for such a statement in a Qt project file?
↧