From: Rico Tzschichholz Date: Wed, 3 Mar 2021 16:01:41 +0000 (+0100) Subject: vala: Report warning if --target-glib=auto was not evaluated successfully X-Git-Tag: 0.51.90~17 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=70abd9550e9efbed373a615b7a2a89e0e05653bc;p=thirdparty%2Fvala.git vala: Report warning if --target-glib=auto was not evaluated successfully and don't try to process the valid "auto" string any further. --- diff --git a/vala/valacodecontext.vala b/vala/valacodecontext.vala index d2e550f03..9e78cc0c8 100644 --- a/vala/valacodecontext.vala +++ b/vala/valacodecontext.vala @@ -634,8 +634,10 @@ public class Vala.CodeContext { if (available_glib != null && available_glib.scanf ("%d.%d", out glib_major, out glib_minor) >= 2) { glib_minor -= ++glib_minor % 2; set_target_glib_version ("%d.%d".printf (glib_major, glib_minor)); - return; + } else { + Report.warning (null, "Could not determine the version of `glib-2.0', target version of glib was not set"); } + return; } glib_major = target_glib_major;