[Spice-commits] 2 commits - src/usbutil.c src/vncdisplaykeymap.c

Pavel Grunt pgrunt at kemper.freedesktop.org
Mon Nov 14 10:25:05 UTC 2016


 src/usbutil.c          |    3 +++
 src/vncdisplaykeymap.c |    4 ++++
 2 files changed, 7 insertions(+)

New commits:
commit 8b47fe9ef4fd152b87f1e94566c0ed147ffbe812
Author: Pavel Grunt <pgrunt at redhat.com>
Date:   Mon Nov 14 09:24:27 2016 +0100

    vncdisplaykeymap: Include missing headers
    
    Causing build failures on win32
     .libs/vncdisplaykeymap.o: In function `vnc_display_keymap_gdk2xtkbd_table':
      /builddir/build/BUILD/spice-gtk-0.33.19-efbfd/build_win32/src/../../src/vncdisplaykeymap.c:198: undefined reference to `GDK_IS_WIN32_WINDOW'
     collect2: error: ld returned 1 exit status
    
    Regression from 9ff67a108bb76e50a2c85a5054e6521088df1800
    Acked-by: Frediano Ziglio <fziglio at redhat.com>

diff --git a/src/vncdisplaykeymap.c b/src/vncdisplaykeymap.c
index d0c9739..2a79213 100644
--- a/src/vncdisplaykeymap.c
+++ b/src/vncdisplaykeymap.c
@@ -85,11 +85,15 @@ static unsigned int ref_count_for_untranslated_keys = 0;
 #endif
 
 #ifdef GDK_WINDOWING_WIN32
+#include <gdk/gdkwin32.h>
+
 /* Win32 native virtual keycodes */
 #include "vncdisplaykeymap_win322xtkbd.c"
 #endif
 
 #ifdef GDK_WINDOWING_QUARTZ
+#include <gdk/gdkquartz.h>
+
 /* OS-X native keycodes */
 #include "vncdisplaykeymap_osx2xtkbd.c"
 #endif
commit a27a83da30d58511b2a5f2cdb13ebd4fca7a3d0a
Author: Pavel Grunt <pgrunt at redhat.com>
Date:   Tue Nov 1 17:08:01 2016 +0100

    Adjust include header to new location of macros
    
    minor & major macros were moved to sysmacros.h
    
    usbutil.c: In function ‘spice_usbutil_get_sysfs_attribute’:
    usbutil.c:110:14: warning: ‘__major_from_sys_types’ is deprecated:
      In the GNU C Library, `major' is defined by <sys/sysmacros.h>.
      For historical compatibility, it is currently defined by
      <sys/types.h> as well, but we plan to remove this soon.
      To use `major', include <sys/sysmacros.h> directly.
      If you did not intend to use a system-defined macro `major',
      you should #undef it after including <sys/types.h>.
      [-Wdeprecated-declarations]
                  major(stat_buf.st_rdev), minor(stat_buf.st_rdev), attribute);
    
    Acked-by: Victor Toso <victortoso at redhat.com>

diff --git a/src/usbutil.c b/src/usbutil.c
index 7bfbe44..b68a2e1 100644
--- a/src/usbutil.c
+++ b/src/usbutil.c
@@ -30,7 +30,10 @@
 #ifdef __linux__
 #include <stdio.h>
 #include <unistd.h>
+#include <sys/sysmacros.h>
+#ifndef major /* major and minor macros were moved to sys/sysmacros.h from sys/types.h */
 #include <sys/types.h>
+#endif
 #include <sys/stat.h>
 #endif
 #include "usbutil.h"


More information about the Spice-commits mailing list