[gnome-calculator] gclac: no install GIR files if no introspection
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calculator] gclac: no install GIR files if no introspection
- Date: Thu, 24 Feb 2022 02:11:51 +0000 (UTC)
commit 4da8fdcc4396fca1b79a7339fe326662c0809c8b
Author: Daniel Espinosa <esodan gmail com>
Date: Wed Feb 23 20:10:31 2022 -0600
gclac: no install GIR files if no introspection
Fix issue #251
gcalc/meson.build | 9 +++++++--
gci/meson.build | 9 +++++++--
meson.build | 5 +++++
3 files changed, 19 insertions(+), 4 deletions(-)
---
diff --git a/gcalc/meson.build b/gcalc/meson.build
index b43581c9..faab6538 100644
--- a/gcalc/meson.build
+++ b/gcalc/meson.build
@@ -171,7 +171,12 @@ libgcalc = library(VERSIONED_PROJECT_NAME,
meson.current_build_dir() + '/config.h',
],
link_with: [ lib_mpfrg ],
- install : true,
+ install : [
+ true,
+ true,
+ true,
+ introspection,
+ ],
install_dir : [
true,
join_paths (get_option('includedir'), 'gcalc-@0@'.format (API_VERSION), 'gcalc'),
@@ -179,7 +184,7 @@ libgcalc = library(VERSIONED_PROJECT_NAME,
true
])
-if not get_option('disable-introspection') and gobject_introspection.found()
+if introspection
g_ir_compiler = find_program('g-ir-compiler', required: false)
if g_ir_compiler.found()
custom_target('gcalc-typelib',
diff --git a/gci/meson.build b/gci/meson.build
index 5b270d53..24de94bb 100644
--- a/gci/meson.build
+++ b/gci/meson.build
@@ -90,7 +90,12 @@ libgci = library(GCI_VERSIONED_PROJECT_NAME,
meson.current_build_dir() + '/config.h',
],
link_with: [ libgcalc ],
- install : true,
+ install : [
+ true,
+ true,
+ true,
+ introspection,
+ ],
install_dir : [
true,
join_paths (get_option('includedir'), 'gci-@0@'.format (API_VERSION), 'gci'),
@@ -98,7 +103,7 @@ libgci = library(GCI_VERSIONED_PROJECT_NAME,
true
])
-if not get_option('disable-introspection')
+if introspection
if g_ir_compiler.found()
custom_target('gci-typelib',
command: [
diff --git a/meson.build b/meson.build
index 5975f0f3..00081833 100644
--- a/meson.build
+++ b/meson.build
@@ -39,6 +39,11 @@ libsoup = dependency('libsoup-2.4', version: '>= 2.42')
gee = dependency('gee-0.8', version: '>= 0.20.0')
gobject_introspection = dependency('gobject-introspection-1.0', required: false)
+introspection = not get_option('disable-introspection')
+if not gobject_introspection.found()
+introspection = false
+endif
+
# Libraries
cc = meson.get_compiler('c')
valac = meson.get_compiler('vala')
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]