[libgit2-glib] meson: Simplify introspection detection
- From: Alberto Fanjul <albfan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgit2-glib] meson: Simplify introspection detection
- Date: Sat, 5 Feb 2022 08:44:32 +0000 (UTC)
commit 488839125f95fe0fa9395f6ba23f334d5c8aa8f0
Author: Iñigo Martínez <inigomartinez gmail com>
Date: Wed May 22 08:54:28 2019 +0200
meson: Simplify introspection detection
Introspection detection checks if the option is enabled and also
if the `g-ir-scanner` is avaialable in the system.
This check has been simplified by short circuiting the check.
meson.build | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
---
diff --git a/meson.build b/meson.build
index 7a473cb..21fb9da 100644
--- a/meson.build
+++ b/meson.build
@@ -128,11 +128,8 @@ gio_dep = dependency('gio-2.0', version: '>=' + glib_req)
libgit2_dep = dependency('libgit2', version: '>= 0.25.0')
-enable_gir = get_option('introspection')
-if enable_gir
- # XXX: Not nice, but probably our best option
- enable_gir = find_program('g-ir-scanner', required: false).found()
-endif
+# XXX: Not nice, but probably our best option
+enable_gir = get_option('introspection') and find_program('g-ir-scanner', required: false).found()
enable_vapi = get_option('vapi')
if enable_vapi
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]