forked from AuroraMiddleware/gtk
build: Rename 'with-included-immodules' option
We can call it 'included-immodules', and simplify its logic by always attempting to split the value, to avoid turning an array into a string and then back into an array again.
This commit is contained in:
parent
4b7017ef35
commit
d1a8ed0214
@ -26,8 +26,8 @@ option('enable-xinerama', type: 'combo', choices : ['yes', 'no', 'auto'], value
|
|||||||
description : 'Enable support for the Xinerama extension')
|
description : 'Enable support for the Xinerama extension')
|
||||||
option('dynamic-modules', type: 'boolean', value : true,
|
option('dynamic-modules', type: 'boolean', value : true,
|
||||||
description : 'Allow dynamic module loading')
|
description : 'Allow dynamic module loading')
|
||||||
option('with-included-immodules', type: 'string', value : '',
|
option('included-immodules', type: 'string', value : 'none',
|
||||||
description : 'Build the specified input methods into gtk (comma-separated list or "all" or "none")')
|
description : 'Build the specified input methods (comma-separated list, "all", or "none")')
|
||||||
option('documentation', type: 'boolean', value: 'false',
|
option('documentation', type: 'boolean', value: 'false',
|
||||||
description : 'Build API reference and tools documentation')
|
description : 'Build API reference and tools documentation')
|
||||||
option('man-pages', type: 'boolean', value: 'false',
|
option('man-pages', type: 'boolean', value: 'false',
|
||||||
|
@ -32,20 +32,14 @@ all_immodules = [
|
|||||||
all_immodules += backend_immodules
|
all_immodules += backend_immodules
|
||||||
|
|
||||||
# Allow building some or all immodules included
|
# Allow building some or all immodules included
|
||||||
included_immodules = get_option('with-included-immodules')
|
included_immodules = get_option('included-immodules').split(',')
|
||||||
if included_immodules == 'none'
|
if included_immodules.contains('none')
|
||||||
included_immodules = ''
|
included_immodules = []
|
||||||
elif included_immodules == 'all' or included_immodules == 'yes'
|
elif included_immodules.contains('all')
|
||||||
included_immodules = ','.join(all_immodules)
|
included_immodules = all_immodules
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if included_immodules == ''
|
have_included_immodules = included_immodules.length() > 0
|
||||||
have_included_immodules = false
|
|
||||||
included_immodules = []
|
|
||||||
else
|
|
||||||
have_included_immodules = true
|
|
||||||
included_immodules = included_immodules.split(',')
|
|
||||||
endif
|
|
||||||
|
|
||||||
foreach im: included_immodules
|
foreach im: included_immodules
|
||||||
if not all_immodules.contains(im)
|
if not all_immodules.contains(im)
|
||||||
@ -107,5 +101,3 @@ foreach m: method_defs
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
endforeach
|
endforeach
|
||||||
|
|
||||||
# TODO: post-install gtk4-query-immodules run to create immodules.c
|
|
||||||
|
Loading…
Reference in New Issue
Block a user