Skip to content

Commit

Permalink
Fix for build system, ensure qmake gets run every time, to catch git …
Browse files Browse the repository at this point in the history
…hash changes
  • Loading branch information
malcom2073 committed Nov 21, 2013
1 parent d2a1ffb commit e8796c3
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 2 deletions.
12 changes: 10 additions & 2 deletions core/core.pro
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,14 @@ CONFIG += console rtti exceptions

INCLUDEPATH += $$PWD/../lib/core
DEPENDPATH += $$PWD/../lib/core


#Ensure the pro file gets touched at the end of the build, so the next build reruns qmake
gittouch.commands = touch core.pro
QMAKE_EXTRA_TARGETS += gittouch
POST_TARGETDEPS += gittouch


include(QsLog/QsLog.pri)
win32-x-g++ { #Linux based crossplatform 32bit build
message("Building for win32-x-g++")
Expand Down Expand Up @@ -58,8 +66,8 @@ unix {
INSTALLS += target config dashboard
LIBS += -lqwt -lqjson -lGL -lGLU -lglut
INCLUDEPATH += /usr/include/qwt
DEFINES += GIT_COMMIT=$$system(git describe --dirty=-DEV --always)
DEFINES += GIT_HASH=$$system(git log -n 1 --pretty=format:%H)
DEFINES += GIT_COMMIT=$$system(git describe --dirty=-DEV --always)
DEFINES += GIT_HASH=$$system(git log -n 1 --pretty=format:%H)
}
mac {
QMAKE_CXXFLAGS += -Werror
Expand Down
5 changes: 5 additions & 0 deletions emstudio.pro
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,8 @@ core.depends += lib
plugins.depend += lib
test.depends += lib \
plugins

#Ensure the pro file gets touched at the end of the build, so the next build reruns qmake
gittouch.commands = touch emstudio.pro core/core.pro plugins/freeems/freeems.pro
QMAKE_EXTRA_TARGETS += gittouch
POST_TARGETDEPS += gittouch
6 changes: 6 additions & 0 deletions plugins/freeems/freeems.pro
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ include(../../serialport/apmserial.pri)
QT -= gui
INCLUDEPATH += $$PWD/../../lib/core
DEPENDPATH += $$PWD/../../lib/core

gittouch.commands = touch freeems.pro
QMAKE_EXTRA_TARGETS += gittouch
POST_TARGETDEPS += gittouch


win32-x-g++ { #Linux based crossplatform 32bit build
TARGET = ../../../core/plugins/freeemsplugin
win32:QMAKE_LFLAGS += -shared
Expand Down

0 comments on commit e8796c3

Please sign in to comment.