[Spice-devel] [vdagent-linux v1] Bump glib to 2.38

Victor Toso victortoso at redhat.com
Sat Apr 9 08:08:41 UTC 2016


2.38 is the version that we are using in spice-gtk since:
8693e7d3f7de1ff102082212fa6e35fb1a252ef7

This is also removing glib-compat header as it isn't used anymore.
---
 Makefile.am              |  3 +--
 configure.ac             |  2 +-
 src/glib-compat.h        | 43 -------------------------------------------
 src/vdagent-file-xfers.c |  1 -
 4 files changed, 2 insertions(+), 47 deletions(-)
 delete mode 100644 src/glib-compat.h

diff --git a/Makefile.am b/Makefile.am
index aec3f43..beff6d9 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -28,8 +28,7 @@ else
 src_spice_vdagentd_SOURCES += src/dummy-session-info.c
 endif
 
-noinst_HEADERS = src/glib-compat.h \
-                 src/session-info.h \
+noinst_HEADERS = src/session-info.h \
                  src/udscs.h \
                  src/vdagent-audio.h \
                  src/vdagent-file-xfers.h \
diff --git a/configure.ac b/configure.ac
index 6ddada1..cca53c2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -77,7 +77,7 @@ AC_ARG_ENABLE([static-uinput],
               [enable_static_uinput="$enableval"],
               [enable_static_uinput="no"])
 
-PKG_CHECK_MODULES([GLIB2], [glib-2.0 >= 2.12])
+PKG_CHECK_MODULES([GLIB2], [glib-2.0 >= 2.38])
 PKG_CHECK_MODULES(X, [xfixes xrandr >= 1.3 xinerama x11])
 PKG_CHECK_MODULES(SPICE, [spice-protocol >= 0.12.8])
 PKG_CHECK_MODULES(ALSA, [alsa >= 1.0.22])
diff --git a/src/glib-compat.h b/src/glib-compat.h
deleted file mode 100644
index ba34cb2..0000000
--- a/src/glib-compat.h
+++ /dev/null
@@ -1,43 +0,0 @@
-/*  glib-compat.h
-
-    Copyright 2013 Red Hat, Inc.
-
-    Red Hat Authors:
-    Hans de Goede <hdegoede at redhat.com>
-
-    This program is free software: you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation, either version 3 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-*/
-#ifndef __GLIB_COMPAT_H
-#define __GLIB_COMPAT_H
-
-#include <glib.h>
-
-#if !GLIB_CHECK_VERSION(2,26,0)
-static inline guint64 g_key_file_get_uint64(GKeyFile *file,
-    const gchar *group, const gchar *key, GError **error)
-{
-    gchar *val_str;
-    guint64 val = 0;
-
-    val_str = g_key_file_get_value(file, group, key, error);
-    if (val_str) {
-        val = g_ascii_strtoull(val_str, NULL, 10);
-        g_free(val_str);
-    }
-
-    return val;
-}
-#endif
-
-#endif
diff --git a/src/vdagent-file-xfers.c b/src/vdagent-file-xfers.c
index 13b5b95..48b3069 100644
--- a/src/vdagent-file-xfers.c
+++ b/src/vdagent-file-xfers.c
@@ -38,7 +38,6 @@
 
 #include "vdagentd-proto.h"
 #include "vdagent-file-xfers.h"
-#include "glib-compat.h"
 
 struct vdagent_file_xfers {
     GHashTable *xfers;
-- 
2.5.5



More information about the Spice-devel mailing list