This allows to run it from the build directory without having to specify LD_LIBRARY_PATH. This is particularly useul when working with parts that require special capabilities such as the NetworkDiscovery, given that setcap on a binary disables LD_LIBRARY_LATH loading for security reasons. Building the dpkg package, the rpath will not be added.
40 lines
813 B
Prolog
40 lines
813 B
Prolog
include(../nymea.pri)
|
|
|
|
TARGET = nymead
|
|
TEMPLATE = app
|
|
|
|
INCLUDEPATH += ../libnymea ../libnymea-core $$top_builddir
|
|
|
|
target.path = /usr/bin
|
|
INSTALLS += target
|
|
|
|
QT += sql xml websockets bluetooth dbus network
|
|
|
|
CONFIG += link_pkgconfig
|
|
PKGCONFIG += nymea-zigbee
|
|
|
|
LIBS += -L$$top_builddir/libnymea/ -lnymea \
|
|
-L$$top_builddir/libnymea-core -lnymea-core \
|
|
-lnymea-remoteproxyclient
|
|
|
|
# Add rpath for easy running from the build dir, unless explicitly disabled
|
|
!norpath: {
|
|
message("Adding rpath to nymead binary")
|
|
LIBS += -Wl,-rpath ../libnymea/:../libnymea-core/
|
|
}
|
|
|
|
CONFIG += link_pkgconfig
|
|
PKGCONFIG += nymea-zigbee
|
|
|
|
# Server files
|
|
include(qtservice/qtservice.pri)
|
|
|
|
SOURCES += main.cpp \
|
|
nymeaservice.cpp \
|
|
nymeaapplication.cpp
|
|
|
|
HEADERS += \
|
|
nymeaservice.h \
|
|
nymeaapplication.h
|
|
|