mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-04 15:59:08 -04:00
Detect when gobject-introspection is missing
Instead of a compiler bug error, show a proper error message that asks whether gobject-introspection is installed. Fixes #58.
This commit is contained in:
parent
f6355fe412
commit
42aa91d4d9
3 changed files with 9 additions and 1 deletions
|
@ -39,6 +39,11 @@ class GtkDirective(AstNode):
|
|||
err.hint("Expected 'using Gtk 4.0;'")
|
||||
raise err
|
||||
|
||||
try:
|
||||
gir.get_namespace("Gtk", self.tokens["version"])
|
||||
except:
|
||||
raise CompileError("Could not find GTK 4 introspection files. Is gobject-introspection installed?", fatal=True)
|
||||
|
||||
|
||||
@property
|
||||
def gir_namespace(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue