Browse Source

dbus: add patch to fix cmake tmp session search

The tmp file location cannot be set explicitly. It is set incorrectly by
cmake. This patch only searches for this location if it is not specified
via the build system. Without this change, the cross compile value is
not correct set on target in the file /usr/share/dbus-1/session.conf.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
lilik-openwrt-22.03
Florian Eckert 3 years ago
parent
commit
7fb856d9b8
1 changed files with 27 additions and 0 deletions
  1. +27
    -0
      utils/dbus/patches/020-cmake-fix-tmp-session-search.patch

+ 27
- 0
utils/dbus/patches/020-cmake-fix-tmp-session-search.patch View File

@ -0,0 +1,27 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -471,14 +471,16 @@ endif()
#### Find socket directories
if(UNIX)
- if(NOT $ENV{TMPDIR} STREQUAL "")
- set(DBUS_SESSION_SOCKET_DIR $ENV{TMPDIR})
- elseif(NOT $ENV{TEMP} STREQUAL "")
- set(DBUS_SESSION_SOCKET_DIR $ENV{TEMP})
- elseif(NOT $ENV{TMP} STREQUAL "")
- set(DBUS_SESSION_SOCKET_DIR $ENV{TMP})
- else()
- set(DBUS_SESSION_SOCKET_DIR /tmp)
+ if(NOT DEFINED DBUS_SESSION_SOCKET_DIR)
+ if(NOT $ENV{TMPDIR} STREQUAL "")
+ set(DBUS_SESSION_SOCKET_DIR $ENV{TMPDIR})
+ elseif(NOT $ENV{TEMP} STREQUAL "")
+ set(DBUS_SESSION_SOCKET_DIR $ENV{TEMP})
+ elseif(NOT $ENV{TMP} STREQUAL "")
+ set(DBUS_SESSION_SOCKET_DIR $ENV{TMP})
+ else()
+ set(DBUS_SESSION_SOCKET_DIR /tmp)
+ endif()
endif()
endif()

Loading…
Cancel
Save