summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2017-11-29 18:01:40 +0100
committerBastien Nocera <hadess@hadess.net>2017-12-05 06:46:55 +0100
commit328b53f0b67293c5b310d4e1ce9894a83644416f (patch)
tree6e7713057fa63a86e1976c1d8163df52f222462a
parentb99e04f116972d2ee355fb129238cc574bd58dd3 (diff)
downloadgdk-pixbuf-328b53f0b67293c5b310d4e1ce9894a83644416f.tar.gz
build: Remove "enable" from Meson build options
As per https://wiki.gnome.org/Initiatives/GnomeGoals/MesonPorting https://bugzilla.gnome.org/show_bug.cgi?id=790995
-rw-r--r--gdk-pixbuf/meson.build12
-rw-r--r--meson.build20
-rw-r--r--meson_options.txt18
3 files changed, 25 insertions, 25 deletions
diff --git a/gdk-pixbuf/meson.build b/gdk-pixbuf/meson.build
index 77c162bfc..a02177c70 100644
--- a/gdk-pixbuf/meson.build
+++ b/gdk-pixbuf/meson.build
@@ -6,12 +6,12 @@ subdir('pixops')
# - conditional, otherwise always built
# We need to disable the in-house loaders for BMP, GIF and ICO
-# when enable_native_windows_loaders is true
+# when native_windows_loaders is true
loaders = [
[ 'png', [ 'io-png.c' ], enabled_loaders.contains('png') ],
- [ 'bmp', [ 'io-bmp.c' ], not enable_native_windows_loaders ],
- [ 'gif', [ 'io-gif.c', 'io-gif-animation.c' ], not enable_native_windows_loaders ],
- [ 'ico', [ 'io-ico.c' ], not enable_native_windows_loaders ],
+ [ 'bmp', [ 'io-bmp.c' ], not native_windows_loaders ],
+ [ 'gif', [ 'io-gif.c', 'io-gif-animation.c' ], not native_windows_loaders ],
+ [ 'ico', [ 'io-ico.c' ], not native_windows_loaders ],
[ 'ani', [ 'io-ani.c', 'io-ani-animation.c' ] ],
[ 'jpeg', [ 'io-jpeg.c' ], enabled_loaders.contains('jpeg') ],
[ 'pnm', [ 'io-pnm.c' ] ],
@@ -133,7 +133,7 @@ windows_native_loader_formats = [ 'bmp', 'emf', 'gif', 'ico', 'jpeg', 'tiff', 'w
windows_base_loader_sources = [ 'io-gdip-utils.c', 'io-gdip-animation.c' ]
# Build the loaders using native Windows components as static modules, if requested
-if enable_native_windows_loaders
+if native_windows_loaders
if builtin_loaders.contains('windows') or builtin_all_loaders
cflag_for_included_loader = ['-DINCLUDE_gdiplus']
included_loaders_cflags += cflag_for_included_loader
@@ -193,7 +193,7 @@ foreach l: loaders
endforeach
# Build the loaders using native Windows components as dynamic modules, if requested
-if enable_native_windows_loaders
+if native_windows_loaders
if not (builtin_loaders.contains('windows') or builtin_all_loaders)
foreach loader: windows_native_loader_formats
loader_sources = windows_base_loader_sources + [ 'io-gdip-@0@.c'.format(loader) ]
diff --git a/meson.build b/meson.build
index 466a5c3e3..4bd0af53f 100644
--- a/meson.build
+++ b/meson.build
@@ -214,7 +214,7 @@ endif
enabled_loaders = []
loaders_deps = []
-if get_option('enable_png')
+if get_option('png')
# We have a vast selection of libpng versions to choose from
foreach png: [ 'libpng16', 'libpng15', 'libpng14', 'libpng13', 'libpng12', 'libpng10' ]
if not enabled_loaders.contains('png')
@@ -260,19 +260,19 @@ endif
# Note that we currently do not use the native Windows loaders to handle PNG and
# JPEG2000 images
if host_system == 'windows'
- enable_native_windows_loaders = get_option('enable_native_windows_loaders')
+ native_windows_loaders = get_option('native_windows_loaders')
else
- enable_native_windows_loaders = false
+ native_windows_loaders = false
endif
-if enable_native_windows_loaders
+if native_windows_loaders
loaders_deps += cc.find_library('gdiplus')
loaders_deps += cc.find_library('ole32')
enabled_loaders += 'gdiplus'
endif
-# Don't check and build the jpeg loader if enable_native_windows_loaders is true
-if get_option('enable_jpeg') and not enable_native_windows_loaders
+# Don't check and build the jpeg loader if native_windows_loaders is true
+if get_option('jpeg') and not native_windows_loaders
if cc.has_header('jpeglib.h')
jpeg_dep = cc.find_library('jpeg', required: false)
if cc.get_id() == 'msvc' and not jpeg_dep.found()
@@ -290,8 +290,8 @@ if get_option('enable_jpeg') and not enable_native_windows_loaders
endif
endif
-# Don't check and build the tiff loader if enable_native_windows_loaders is true
-if get_option('enable_tiff') and not enable_native_windows_loaders
+# Don't check and build the tiff loader if native_windows_loaders is true
+if get_option('tiff') and not native_windows_loaders
tiff_dep = dependency('libtiff-4', required: false)
if not tiff_dep.found()
# Fallback when no pkg-config file is found for libtiff on MSVC, which is quite normal
@@ -314,7 +314,7 @@ endif
jasper_extra_cflags = []
-if get_option('enable_jasper')
+if get_option('jasper')
has_jasper_header = false
if cc.get_id() == 'msvc'
@@ -347,7 +347,7 @@ endif
if host_system == 'windows'
relocatable = true
else
- relocatable = get_option('enable_relocatable')
+ relocatable = get_option('relocatable')
endif
if relocatable
diff --git a/meson_options.txt b/meson_options.txt
index 9eadfcc4c..a197b7434 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -1,16 +1,16 @@
-option('enable_png',
+option('png',
description: 'Enable PNG loader (requires libpng)',
type: 'boolean',
value: true)
-option('enable_tiff',
- description: 'Enable TIFF loader (requires libtiff), disabled on Windows if "enable_native_windows_loaders" is used',
+option('tiff',
+ description: 'Enable TIFF loader (requires libtiff), disabled on Windows if "native_windows_loaders" is used',
type: 'boolean',
value: true)
-option('enable_jpeg',
- description: 'Enable JPEG loader (requires libjpeg), disabled on Windows if "enable_native_windows_loaders" is used',
+option('jpeg',
+ description: 'Enable JPEG loader (requires libjpeg), disabled on Windows if "native_windows_loaders" is used',
type: 'boolean',
value: true)
-option('enable_jasper',
+option('jasper',
description: 'Enable JPEG2000 loader (requires libjasper)',
type: 'boolean',
value: false)
@@ -34,11 +34,11 @@ option('with_man',
description: 'Whether to generate man pages (requires xlstproc)',
type: 'boolean',
value: true)
-option('enable_relocatable',
+option('relocatable',
description: 'Whether to enable application bundle relocation support',
type: 'boolean',
value: false)
-option('enable_native_windows_loaders',
- description: 'Use Windows system components to handle BMP, EMF, GIF, ICO, JPEG, TIFF and WMF images, overriding enable_jpeg and enable_tiff. To build this into gdk-pixbuf, pass in windows" with the other loaders to build in or use "all" with the builtin_loaders option',
+option('native_windows_loaders',
+ description: 'Use Windows system components to handle BMP, EMF, GIF, ICO, JPEG, TIFF and WMF images, overriding jpeg and tiff. To build this into gdk-pixbuf, pass in windows" with the other loaders to build in or use "all" with the builtin_loaders option',
type: 'boolean',
value: false)