@@ -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 )
0 commit comments