forked from AuroraMiddleware/gtk
Conditional check for gdesktopappinfo header
GDesktopAppInfo is not available on macOS and needs to be disabled
This commit is contained in:
parent
4e2a263c1f
commit
13b94dab10
@ -284,3 +284,6 @@
|
||||
#mesondefine HAVE_TRACKER3
|
||||
|
||||
#mesondefine HAVE_F16C
|
||||
|
||||
/* Does the OS support GDesktopAppInfo? */
|
||||
#mesondefine HAVE_DESKTOPAPPINFO
|
||||
|
@ -27,7 +27,9 @@
|
||||
#include "gdkdisplay-x11.h"
|
||||
|
||||
#include <glib.h>
|
||||
#ifdef HAVE_DESKTOPAPPINFO
|
||||
#include <gio/gdesktopappinfo.h>
|
||||
#endif
|
||||
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
@ -349,10 +351,11 @@ gdk_x11_app_launch_context_get_startup_notify_id (GAppLaunchContext *context,
|
||||
workspace_str = g_strdup_printf ("%d", ctx->workspace);
|
||||
else
|
||||
workspace_str = NULL;
|
||||
|
||||
#ifdef HAVE_DESKTOPAPPINFO
|
||||
if (G_IS_DESKTOP_APP_INFO (info))
|
||||
application_id = g_desktop_app_info_get_filename (G_DESKTOP_APP_INFO (info));
|
||||
else
|
||||
#endif
|
||||
application_id = NULL;
|
||||
|
||||
startup_id = g_strdup_printf ("%s-%lu-%s-%s-%d_TIME%lu",
|
||||
|
@ -177,6 +177,7 @@ check_headers = [
|
||||
'sys/time.h',
|
||||
'sys/types.h',
|
||||
'unistd.h',
|
||||
'gio/gdesktopappinfo.h'
|
||||
]
|
||||
|
||||
foreach h : check_headers
|
||||
|
Loading…
Reference in New Issue
Block a user