Skip to content

Commit 07084a5

Browse files
committed
tools build: add profile
To select supported_application_profiles attribute from targets
1 parent 5df3c91 commit 07084a5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tools/build_api.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ def transform_release_toolchains(target, version):
400400
else:
401401
return target.supported_toolchains
402402

403-
def get_mbed_official_release(version):
403+
def get_mbed_official_release(version, profile=None):
404404
""" Given a release version string, return a tuple that contains a target
405405
and the supported toolchains for that release.
406406
Ex. Given '2', return (('LPC1768', ('ARM', 'GCC_ARM')),
@@ -426,7 +426,8 @@ def get_mbed_official_release(version):
426426
TARGET_MAP[target].name,
427427
tuple(['ARM', 'GCC_ARM'])
428428
]
429-
) for target in TARGET_NAMES
429+
) for target in TARGET_NAMES \
430+
if not profile or profile in TARGET_MAP[target].supported_application_profiles
430431
)
431432
)
432433

0 commit comments

Comments
 (0)