[vala/0.40] glib-2.0: Guard Pid.to_string() with GLIB_2_50 to deal with G_PID_FORMAT



commit f7fc53ecefa6842ee351d5f0d9909cd8613481b9
Author: Rico Tzschichholz <ricotz ubuntu com>
Date:   Thu Apr 16 10:00:21 2020 +0200

    glib-2.0: Guard Pid.to_string() with GLIB_2_50 to deal with G_PID_FORMAT
    
    Otherwise building with glib-2.0 < 2.50 breaks due availability check of
    GLib.Pid.FORMAT.

 vapi/glib-2.0.vapi | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/vapi/glib-2.0.vapi b/vapi/glib-2.0.vapi
index f32602a3d..512c0cec2 100644
--- a/vapi/glib-2.0.vapi
+++ b/vapi/glib-2.0.vapi
@@ -1891,8 +1891,10 @@ namespace GLib {
                [Version (since = "2.50")]
                public const string FORMAT;
 
+#if GLIB_2_50
                [CCode (cname = "g_strdup_printf", instance_pos = -1)]
                public string to_string (string format = "%" + FORMAT);
+#endif
        }
 
        public delegate void ChildWatchFunc (Pid pid, int status);


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