[vala] Require and target GLib >= 2.24



commit 9e95df0f49fa0f2933dd3a83ab5c0c4187824379
Author: Rico Tzschichholz <ricotz ubuntu com>
Date:   Thu May 29 22:17:42 2014 +0200

    Require and target GLib >= 2.24
    
    The next stable release of vala will happen four years after the
    release of GLib 2.24.0.

 compiler/valacompiler.vala |    2 +-
 configure.ac               |    2 +-
 vapi/glib-2.0.vapi         |   20 --------------------
 3 files changed, 2 insertions(+), 22 deletions(-)
---
diff --git a/compiler/valacompiler.vala b/compiler/valacompiler.vala
index 6ac1e1c..4a20ea1 100644
--- a/compiler/valacompiler.vala
+++ b/compiler/valacompiler.vala
@@ -251,7 +251,7 @@ class Vala.Compiler {
                }
 
                int glib_major = 2;
-               int glib_minor = 18;
+               int glib_minor = 24;
                if (target_glib != null && target_glib.scanf ("%d.%d", out glib_major, out glib_minor) != 2) {
                        Report.error (null, "Invalid format for --target-glib");
                }
diff --git a/configure.ac b/configure.ac
index a0d0abd..4b11904 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,7 +65,7 @@ AC_SUBST(COVERAGE_VALAFLAGS)
 AC_SUBST(COVERAGE_CFLAGS)
 AC_SUBST(COVERAGE_LIBS)
 
-GLIB_REQUIRED=2.18.0
+GLIB_REQUIRED=2.24.0
 
 PKG_CHECK_MODULES(GLIB, glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED)
 
diff --git a/vapi/glib-2.0.vapi b/vapi/glib-2.0.vapi
index 4f31c74..f443f0b 100644
--- a/vapi/glib-2.0.vapi
+++ b/vapi/glib-2.0.vapi
@@ -3246,11 +3246,7 @@ namespace GLib {
        }
 
        [Compact]
-#if GLIB_2_22
        [CCode (ref_function = "g_mapped_file_ref", unref_function = "g_mapped_file_unref")]
-#else
-       [CCode (free_function = "g_mapped_file_free")]
-#endif
        public class MappedFile {
                public MappedFile (string filename, bool writable) throws FileError;
                public size_t get_length ();
@@ -4342,11 +4338,7 @@ namespace GLib {
        /* Pointer Arrays */
 
        [Compact, Deprecated (since = "vala-0.26", replacement="GenericArray")]
-#if GLIB_2_22
        [CCode (ref_function = "g_ptr_array_ref", unref_function = "g_ptr_array_unref", type_id = 
"G_TYPE_PTR_ARRAY")]
-#else
-       [CCode (free_function = "g_ptr_array_free")]
-#endif
        public class PtrArray {
                public PtrArray ();
                public PtrArray.with_free_func (GLib.DestroyNotify? element_free_func);
@@ -4465,11 +4457,7 @@ namespace GLib {
        /* Byte Arrays */
 
        [Compact]
-#if GLIB_2_22
        [CCode (cprefix = "g_byte_array_", ref_function = "g_byte_array_ref", unref_function = 
"g_byte_array_unref", type_id = "G_TYPE_BYTE_ARRAY")]
-#else
-       [CCode (cprefix = "g_byte_array_", free_function = "g_byte_array_free")]
-#endif
        public class ByteArray {
                public ByteArray ();
                [CCode (cname = "g_byte_array_sized_new")]
@@ -4596,11 +4584,7 @@ namespace GLib {
        /* GArray */
 
        [Compact]
-#if GLIB_2_22
        [CCode (ref_function = "g_array_ref", unref_function = "g_array_unref", type_id = "G_TYPE_ARRAY")]
-#else
-       [CCode (free_function = "g_array_free")]
-#endif
        public class Array<G> {
                [CCode (cname = "len")]
                public uint length;
@@ -4641,11 +4625,7 @@ namespace GLib {
        public delegate int TreeSearchFunc<K> (K key);
 
        [Compact]
-#if GLIB_2_22
        [CCode (ref_function = "g_tree_ref", unref_function = "g_tree_unref")]
-#else
-       [CCode (free_function = "g_tree_destroy")]
-#endif
        public class Tree<K,V> {
                [CCode (cname = "g_tree_new_full", simple_generics = true)]
                public Tree (CompareDataFunc<K> key_compare_func);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]