[gtk/wip/nirbheek/gtk-3-24-meson: 2/7] gtk-launch: Fix compilation with MSVC
- From: Nirbheek Chauhan <nirbheekc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/nirbheek/gtk-3-24-meson: 2/7] gtk-launch: Fix compilation with MSVC
- Date: Sun, 25 Nov 2018 17:46:18 +0000 (UTC)
commit 0d285bcbf1df13c53bbb4e3f19b0ceadf6aa4bf2
Author: Nirbheek Chauhan <nirbheek centricular com>
Date: Tue Nov 20 16:08:02 2018 +0530
gtk-launch: Fix compilation with MSVC
gtk/gtk-launch.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/gtk/gtk-launch.c b/gtk/gtk-launch.c
index ccf1bd8d4b..87b351bf2a 100644
--- a/gtk/gtk-launch.c
+++ b/gtk/gtk-launch.c
@@ -21,7 +21,9 @@
#include <config.h>
#include <stdio.h>
+#ifdef HAVE_UNISTD_H
#include <unistd.h>
+#endif
#include <locale.h>
#include <errno.h>
@@ -136,7 +138,9 @@ main (int argc, char *argv[])
info = G_APP_INFO (g_desktop_app_info_new (desktop_file_name));
g_free (desktop_file_name);
#else
-#warning Please add support for creating AppInfo from id for your OS
+ #ifndef _MSC_VER
+ #warning Please add support for creating AppInfo from id for your OS
+ #endif
g_printerr (_("Creating AppInfo from id not supported on non unix operating systems"));
#endif
args++;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]