vala vapigen fails with vala older than 0.54
After commit 260a3707, the GIR now contains Gio.TlsProtocolVersion; because of that, the libsoup-3.0.vapi generation fails with vala older than 0.54, as the pregenerated gio-3.0.vapi in older vala versions doesn't have the symbols from glib-2.70. vala-0.53.1 has:
- gio-2.0,glib-2.0: Add new symbols from 2.69.0
And then it all leads to quite a mysterious error during build:
[241/242] Generating libsoup-3.0.vapi with a custom command
FAILED: libsoup/libsoup-3.0.vapi
/usr/bin/vapigen-0.52 --quiet --library=libsoup-3.0 --directory=/home/leio/Projects/libsoup/build/libsoup --pkg=gio-2.0 --metadatadir=/home/leio/Projects/libsoup/libsoup /home/leio/Projects/libsoup/build/libsoup/Soup-3.0.gir /home/leio/Projects/libsoup/libsoup/Soup-3.0-custom.vala
Soup-3.0.gir:6489.95-6489.95: error: The type name `GLib.TlsProtocolVersion' could not be found
Soup-3.0.gir:7115.54-7115.54: error: The type name `GLib.TlsProtocolVersion' could not be found
Soup-3.0.gir:7115.54-7115.54: error: The type name `GLib.TlsProtocolVersion' could not be found
[242/242] Generating Soup-3.0.typelib with a custom command
ninja: build stopped: subcommand failed.
as when you look into the Soup-3.0.gir that the gobject-introspection spec made into build dir, it has them properly in Gio
namespace, not what the error message claims.
I don't expect anything to really happen about this report, but it may serve as a discussion point about glib-2.70 API in vala LTS releases, the confusing error message or just a way for others to find the error message and pinpoint the problem to "too old vala".