Generate DBus session.conf from template for each platform individually

Before this commit we used to have a static session.conf. But the session
configuration needs to be different for Mac OS and Windows. Our static
one was Windows only. This caused the packaged DBus daemon to fail on
Mac OS.
This commit solves this by generating the config file at qmake time with
special configuration for each operating system.

ref T170
This commit is contained in:
Roland Winklmeier
2017-10-04 11:26:37 +02:00
parent 0cf6034a29
commit 17ed39827a
2 changed files with 52 additions and 31 deletions

View File

@@ -70,7 +70,24 @@ win32-g++ {
DESTDIR = $$DestRoot/lib
DLLDESTDIR = $$DestRoot/bin
OTHER_FILES += $$TRANSLATIONS readme.txt buildconfig.cpp.in
OTHER_FILES += $$TRANSLATIONS readme.txt share/dbus-1/session.conf.in
win32 {
DBUS_SESSION_BUS_LISTEN_ADDRESS = "autolaunch:"
DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL = "<!--<auth>EXTERNAL</auth>-->"
}
macx {
DBUS_SESSION_BUS_LISTEN_ADDRESS = "launchd:env=DBUS_LAUNCHD_SESSION_BUS_SOCKET"
DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL = "<auth>EXTERNAL</auth>"
}
win32|macx {
dbus_session_conf.input = share/dbus-1/session.conf.in
dbus_session_conf.output = $$DestRoot/share/dbus-1/session.conf
QMAKE_SUBSTITUTES += dbus_session_conf
}
win32 {
dlltarget.path = $$PREFIX/bin
@@ -80,4 +97,8 @@ win32 {
INSTALLS += target
}
package_dbus_conf.path = $$PREFIX/share/dbus-1
package_dbus_conf.files += $$DestRoot/share/dbus-1/*.conf
INSTALLS += package_dbus_conf
load(common_post)