Correct test finding behavior

Scan resources ignores the build dir so we can't set it to something
dumb like the directory we want to scan
pull/6644/head
Jimmy Brisson 2018-04-24 10:07:16 -05:00
parent bc8b98358d
commit da69f0165b
2 changed files with 4 additions and 4 deletions

View File

@ -2077,9 +2077,8 @@ def find_tests(base_dir, target_name, toolchain_name, app_config=None):
commons = []
# Prepare the toolchain
toolchain = prepare_toolchain(
[base_dir], base_dir, target_name, toolchain_name, silent=True,
app_config=app_config)
toolchain = prepare_toolchain([base_dir], None, target_name, toolchain_name,
silent=True, app_config=app_config)
# Scan the directory for paths to probe for 'TESTS' folders
base_resources = scan_resources([base_dir], toolchain)

View File

@ -360,7 +360,8 @@ class ARMC6(ARM_STD):
self.flags['common'].append("-mcmse")
# Create Secure library
if target.core == "Cortex-M23" or self.target.core == "Cortex-M33":
if ((target.core == "Cortex-M23" or self.target.core == "Cortex-M33") and
kwargs.get('build_dir', False)):
build_dir = kwargs['build_dir']
secure_file = join(build_dir, "cmse_lib.o")
self.flags["ld"] += ["--import_cmse_lib_out=%s" % secure_file]