Build X11 session management only if dependencies are found
This fixes the build breakage caused by Change I50b33d05 when attempting to compile on Linux with session management enabled but libSM and/or libICE not present. Change-Id: I127f32e7041deb2ff968eae8458fee7d4e95d7a5 Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch> Reviewed-by: Bernd Weimer <bweimer@blackberry.com> Reviewed-by: aavit <eirik.aavitsland@digia.com>
This commit is contained in:
parent
de1f9bdc15
commit
132190c3a2
@ -443,7 +443,7 @@ QByteArray QXcbIntegration::wmClass() const
|
|||||||
return m_wmClass;
|
return m_wmClass;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef QT_NO_SESSIONMANAGER
|
#if !defined(QT_NO_SESSIONMANAGER) && defined(XCB_USE_SM)
|
||||||
QPlatformSessionManager *QXcbIntegration::createPlatformSessionManager(const QString &id, const QString &key) const
|
QPlatformSessionManager *QXcbIntegration::createPlatformSessionManager(const QString &id, const QString &key) const
|
||||||
{
|
{
|
||||||
return new QXcbSessionManager(id, key);
|
return new QXcbSessionManager(id, key);
|
||||||
|
@ -101,7 +101,7 @@ public:
|
|||||||
|
|
||||||
QByteArray wmClass() const;
|
QByteArray wmClass() const;
|
||||||
|
|
||||||
#ifndef QT_NO_SESSIONMANAGER
|
#if !defined(QT_NO_SESSIONMANAGER) && defined(XCB_USE_SM)
|
||||||
QPlatformSessionManager *createPlatformSessionManager(const QString &id, const QString &key) const Q_DECL_OVERRIDE;
|
QPlatformSessionManager *createPlatformSessionManager(const QString &id, const QString &key) const Q_DECL_OVERRIDE;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -74,6 +74,7 @@ contains(QT_CONFIG, xcb-render) {
|
|||||||
|
|
||||||
# build with session management support
|
# build with session management support
|
||||||
contains(QT_CONFIG, xcb-sm) {
|
contains(QT_CONFIG, xcb-sm) {
|
||||||
|
DEFINES += XCB_USE_SM
|
||||||
LIBS += -lSM -lICE
|
LIBS += -lSM -lICE
|
||||||
SOURCES += qxcbsessionmanager.cpp
|
SOURCES += qxcbsessionmanager.cpp
|
||||||
HEADERS += qxcbsessionmanager.h
|
HEADERS += qxcbsessionmanager.h
|
||||||
|
Loading…
Reference in New Issue
Block a user