We've to use a small lib in our GUI written in C. I've integrated the lib with the following pro
DEPENDPATH += .
INCLUDEPATH += .
DEFINES += __i386__
unix:DEFINES += _LINUX
window:DEFINES += _WIN32
HEADERS += rttTmsCommLib.h
SOURCES += rttTmsCommLib.c
TARGET = rttTmsComm
unix:TEMPLATE = lib
windows:TEMPLATE =vclib
CONFIG += staticlib
asts-tms-tp-monitor {
TARGET = asts-tms-tp-monitor
unix:TEMPLATE = app
win32:TEMPLATE = vcapp
CONFIG -= staticlib
CONFIG += static
HEADERS += asts-tms-tp-monitor.h
SOURCES += asts-tms-tp-monitor.c
}
tmsdemoclient {
TARGET = tmsdemoclient
unix:TEMPLATE = app
win32:TEMPLATE = vcapp
CONFIG -= staticlib
CONFIG += static
SOURCES += tmsdemoclient.c
}
DEPENDPATH += .
INCLUDEPATH += .
DEFINES += __i386__
unix:DEFINES += _LINUX
window:DEFINES += _WIN32
HEADERS += rttTmsCommLib.h
SOURCES += rttTmsCommLib.c
TARGET = rttTmsComm
unix:TEMPLATE = lib
windows:TEMPLATE =vclib
CONFIG += staticlib
asts-tms-tp-monitor {
TARGET = asts-tms-tp-monitor
unix:TEMPLATE = app
win32:TEMPLATE = vcapp
CONFIG -= staticlib
CONFIG += static
HEADERS += asts-tms-tp-monitor.h
SOURCES += asts-tms-tp-monitor.c
}
tmsdemoclient {
TARGET = tmsdemoclient
unix:TEMPLATE = app
win32:TEMPLATE = vcapp
CONFIG -= staticlib
CONFIG += static
SOURCES += tmsdemoclient.c
}
To copy to clipboard, switch view to plain text mode
the file is invoced with SUBDIRS and works really nice under Windows and Linux. I can also use
qmake -config asts-tms-tp-monitor
qmake -config tmsdemoclient
qmake -config asts-tms-tp-monitor
qmake -config tmsdemoclient
To copy to clipboard, switch view to plain text mode
to build the democlient and the monitor. But now I want that the 2 additional targets are also build when the lib is build (like make all -> rttTmsCommLib asts-tms-tp-monitor tmsdemoclient) and I don't know how to archieve this
Bookmarks