build: Conditionally generate introspection
We not only want to use the "introspection" option: we also want to avoid building when cross-compiling, and if the introspection tools are not available. GTK's main development branch already has a fairly well tested check, so let's backport it.
This commit is contained in:
parent
d960720156
commit
4b8cdeec09
@ -866,7 +866,10 @@ if os_darwin
|
|||||||
module_suffix = 'so'
|
module_suffix = 'so'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
build_gir = get_option('introspection')
|
# Introspection
|
||||||
|
gir = find_program('g-ir-scanner', required : get_option('introspection'))
|
||||||
|
build_gir = gir.found() and (not meson.is_cross_build() or get_option('introspection'))
|
||||||
|
|
||||||
subdir('gdk')
|
subdir('gdk')
|
||||||
subdir('gtk')
|
subdir('gtk')
|
||||||
subdir('modules')
|
subdir('modules')
|
||||||
|
Loading…
Reference in New Issue
Block a user