@@ -2169,7 +2169,7 @@ def status_(ignore=False):
2169
2169
dict (name = ['-c' , '--clean' ], action = 'store_true' , help = 'Clean the build directory before compiling' ),
2170
2170
dict (name = ['-f' , '--flash' ], action = 'store_true' , help = 'Flash the built firmware onto a connected target.' ),
2171
2171
dict (name = ['-N' , '--artifact-name' ], help = 'Name of the built program or library' ),
2172
- dict (name = ['-S' , '--supported' ], dest = 'supported' , action = 'store_true' , help = 'Shows supported matrix of targets and toolchains' ),
2172
+ dict (name = ['-S' , '--supported' ], dest = 'supported' , const = "matrix" , choices = [ "matrix" , "toolchains" , "targets" ], nargs = "?" , help = 'Shows supported matrix of targets and toolchains' ),
2173
2173
dict (name = '--app-config' , dest = "app_config" , help = "Path of an app configuration file (Default is to look for 'mbed_app.json')" ),
2174
2174
help = 'Compile code using the mbed build tools' ,
2175
2175
description = ("Compile this program using the mbed build tools." ))
@@ -2192,8 +2192,8 @@ def compile_(toolchain=None, target=None, profile=False, compile_library=False,
2192
2192
source = [os .path .relpath (program .path , orig_path )]
2193
2193
2194
2194
if supported :
2195
- popen ([python_cmd , '-u' , os .path .join (tools_dir , 'make.py' )]
2196
- + (['-S' ] if supported else []) + (['-v' ] if very_verbose else [])
2195
+ popen (['python' , '-u' , os .path .join (tools_dir , 'make.py' )]
2196
+ + (['-S' , supported ] if supported else []) + (['-v' ] if very_verbose else [])
2197
2197
+ (['--app-config' , app_config ] if app_config else [])
2198
2198
+ args ,
2199
2199
env = env )
@@ -2383,7 +2383,7 @@ def test_(toolchain=None, target=None, compile_list=False, run_list=False, compi
2383
2383
dict (name = ['-m' , '--target' ], help = 'Export for target MCU. Example: K64F, NUCLEO_F401RE, NRF51822...' ),
2384
2384
dict (name = '--source' , action = 'append' , help = 'Source directory. Default: . (current dir)' ),
2385
2385
dict (name = ['-c' , '--clean' ], action = 'store_true' , help = 'Clean the build directory before compiling' ),
2386
- dict (name = ['-S' , '--supported' ], dest = 'supported' , action = 'store_true' , help = 'Shows supported matrix of targets and toolchains' ),
2386
+ dict (name = ['-S' , '--supported' ], dest = 'supported' , const = "matrix" , choices = [ "matrix" , "ides" ], nargs = "?" , help = 'Shows supported matrix of targets and toolchains' ),
2387
2387
dict (name = '--app-config' , dest = "app_config" , help = "Path of an app configuration file (Default is to look for 'mbed_app.json')" ),
2388
2388
help = 'Generate an IDE project' ,
2389
2389
description = (
@@ -2404,8 +2404,8 @@ def export(ide=None, target=None, source=False, clean=False, supported=False, ap
2404
2404
env = program .get_env ()
2405
2405
2406
2406
if supported :
2407
- popen ([python_cmd , '-u' , os .path .join (tools_dir , 'project.py' )]
2408
- + (['-S' ] if supported else []) + (['-v' ] if very_verbose else []),
2407
+ popen (['python' , '-u' , os .path .join (tools_dir , 'project.py' )]
2408
+ + (['-S' , supported ] if supported else []) + (['-v' ] if very_verbose else []),
2409
2409
env = env )
2410
2410
return
2411
2411
0 commit comments