aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2016-08-27 20:37:29 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2016-08-27 20:37:29 +0300
commit68b0f9dfbff9e6732ebc705abbaceac21f135c48 (patch)
treea4470bec437c2065d9332165e96ef47ca71fd4be
parenta29219d1c37fbe52e34b375cc964b7e7019b16aa (diff)
downloadmeson-68b0f9dfbff9e6732ebc705abbaceac21f135c48.zip
meson-68b0f9dfbff9e6732ebc705abbaceac21f135c48.tar.gz
meson-68b0f9dfbff9e6732ebc705abbaceac21f135c48.tar.bz2
Expose all builtin options.
-rw-r--r--mesonbuild/mintro.py26
1 files changed, 7 insertions, 19 deletions
diff --git a/mesonbuild/mintro.py b/mesonbuild/mintro.py
index 14f82a6..76efdac 100644
--- a/mesonbuild/mintro.py
+++ b/mesonbuild/mintro.py
@@ -86,25 +86,11 @@ def list_target_files(target_name, coredata, builddata):
print(json.dumps(sources))
def list_buildoptions(coredata, builddata):
- buildtype= {'choices': ['plain', 'debug', 'debugoptimized', 'release', 'minsize'],
- 'type' : 'combo',
- 'value' : coredata.get_builtin_option('buildtype'),
- 'description' : 'Build type',
- 'name' : 'type'}
- strip = {'value' : coredata.get_builtin_option('strip'),
- 'type' : 'boolean',
- 'description' : 'Strip on install',
- 'name' : 'strip'}
- unity = {'value' : coredata.get_builtin_option('unity'),
- 'type' : 'boolean',
- 'description' : 'Unity build',
- 'name' : 'unity'}
- all_opt = []
- all_opt.append({'name' : 'core',
- 'description' : 'Core options',
- 'type' : 'suboption',
- 'value' : [buildtype, strip, unity],
- })
+ all_opt = [{'name' : 'builtin',
+ 'description': 'Meson builtin options',
+ 'type': 'suboption',
+ 'value': get_keys(coredata.builtins),
+ }]
all_opt.append({'name': 'user',
'description' : 'User defined options',
'type' : 'suboption',
@@ -161,6 +147,8 @@ def get_keys(options):
keys = list(options.keys())
keys.sort()
for key in keys:
+ if key == 'backend': # The backend can never be changed.
+ continue
opt = options[key]
optlist.append(opt2dict(key, opt))
return optlist