summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2021-04-08 17:28:02 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2021-04-08 17:28:02 +0100
commitdac7bbac2ed73449a1cfc02745dbcd73f90f0538 (patch)
tree13f96ed1581dcf9c70922476bfe14d13d7658201 /meson.build
parent866670e30907eb534895da26626709ed5f2e419d (diff)
downloadgdk-pixbuf-dac7bbac2ed73449a1cfc02745dbcd73f90f0538.tar.gz
build: Use `type:array` for builtin_loaders option
This gives us an actual array, and lets Meson deal with the argument parsing. It also gives us a default value that we can specify in the meson_options.txt.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build12
1 files changed, 3 insertions, 9 deletions
diff --git a/meson.build b/meson.build
index b84d804c7..0241fcde0 100644
--- a/meson.build
+++ b/meson.build
@@ -237,21 +237,15 @@ else
endif
gdk_pixbuf_conf.set('USE_GMODULE', build_modules)
-# We want these loaders to be built into gdk-pixbuf unless
-# the builtin_loaders option specifies otherwise
-default_builtin_loaders = [ 'png', 'jpeg' ]
-
# Check which loaders should be built into gdk-pixbuf
-builtin_loaders = get_option('builtin_loaders').split(',')
+builtin_loaders = get_option('builtin_loaders')
# If 'all' is specified for builtin_loaders, build all
# buildable loaders into gdk-pixbuf
builtin_all_loaders = false
-if builtin_loaders == [ 'all' ]
+if builtin_loaders.contains('all')
builtin_all_loaders = true
-elif builtin_loaders == [ 'default' ]
- builtin_loaders = default_builtin_loaders
-elif builtin_loaders == [ 'none' ]
+elif builtin_loaders.contains('none')
builtin_loaders = []
endif