From 1f45652e3405bd6eedafbcec8db6e7e5e748932b Mon Sep 17 00:00:00 2001 From: Ryo Nakano Date: Sun, 7 Jan 2024 13:55:48 +0900 Subject: [PATCH] Make granite-demo optional We don't need demo in the Flatpak Platform for example, so disabling demo when building for Flatpak should lessen its size and make build time faster a little --- meson.build | 5 ++++- meson_options.txt | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 90ad7b3a8..d831ea8e4 100644 --- a/meson.build +++ b/meson.build @@ -65,13 +65,16 @@ i18n = import('i18n') subdir('lib') subdir('data') -subdir('demo') subdir('po') if get_option('documentation') subdir('doc') endif +if get_option('demo') + subdir('demo') +endif + # set up post-install script to refresh the GTK icon cache meson.add_install_script( join_paths(meson.current_source_dir(), 'meson', 'post_install.py'), diff --git a/meson_options.txt b/meson_options.txt index bd1a1d6f4..d823bfe87 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -1,2 +1,3 @@ option('documentation', type: 'boolean', value: false, description: 'generate documentation with gtk-doc and valadoc') option('introspection', type: 'boolean', value: true, description: 'Whether to build introspection files') +option('demo', type: 'boolean', value: true, description: 'Whether to build granite-demo')