summaryrefslogtreecommitdiff
path: root/platform/linuxbsd/freedesktop_portal_desktop.cpp
diff options
context:
space:
mode:
authorbruvzg <7645683+bruvzg@users.noreply.github.com>2023-02-15 14:13:56 +0200
committerbruvzg <7645683+bruvzg@users.noreply.github.com>2023-02-16 16:38:47 +0200
commitdd068794c3fc811ca3011e63bd74ee50f2ccc591 (patch)
treea69b925d659ff39bdcac8078e5288a4b81c397b7 /platform/linuxbsd/freedesktop_portal_desktop.cpp
parent953383328af17e8c9fd6359285c12617cb22f636 (diff)
[Linux] Make SO wrapper usage optional.
Diffstat (limited to 'platform/linuxbsd/freedesktop_portal_desktop.cpp')
-rw-r--r--platform/linuxbsd/freedesktop_portal_desktop.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/platform/linuxbsd/freedesktop_portal_desktop.cpp b/platform/linuxbsd/freedesktop_portal_desktop.cpp
index 72d4e3772f..ec1fcf6698 100644
--- a/platform/linuxbsd/freedesktop_portal_desktop.cpp
+++ b/platform/linuxbsd/freedesktop_portal_desktop.cpp
@@ -36,7 +36,11 @@
#include "core/os/os.h"
#include "core/string/ustring.h"
+#ifdef SOWRAP_ENABLED
#include "dbus-so_wrap.h"
+#else
+#include <dbus/dbus.h>
+#endif
#include "core/variant/variant.h"
@@ -124,12 +128,16 @@ uint32_t FreeDesktopPortalDesktop::get_appearance_color_scheme() {
}
FreeDesktopPortalDesktop::FreeDesktopPortalDesktop() {
+#ifdef SOWRAP_ENABLED
#ifdef DEBUG_ENABLED
int dylibloader_verbose = 1;
#else
int dylibloader_verbose = 0;
#endif
unsupported = (initialize_dbus(dylibloader_verbose) != 0);
+#else
+ unsupported = false;
+#endif
}
#endif // DBUS_ENABLED