Correctly detect presence of the built library
Use the repo-specific test not just the Mbed TLS specific one. Signed-off-by: David Horstmann <david.horstmann@arm.com>
This commit is contained in:
parent
58cf7c6c38
commit
98af198a30
1 changed files with 7 additions and 7 deletions
|
@ -60,7 +60,13 @@ def main(library_build_dir: str):
|
||||||
|
|
||||||
in_psa_crypto_repo = build_tree.looks_like_psa_crypto_root(mbedtls_dir)
|
in_psa_crypto_repo = build_tree.looks_like_psa_crypto_root(mbedtls_dir)
|
||||||
|
|
||||||
if not os.path.exists(library_build_dir + '/library/libmbedcrypto.a'):
|
if in_psa_crypto_repo:
|
||||||
|
crypto_lib_filename = \
|
||||||
|
library_build_dir + '/core/libpsacrypto.a'
|
||||||
|
else:
|
||||||
|
crypto_lib_filename = library_build_dir + '/library/libmbedcrypto.a'
|
||||||
|
|
||||||
|
if not os.path.exists(crypto_lib_filename):
|
||||||
subprocess.check_call([
|
subprocess.check_call([
|
||||||
'cmake', '.',
|
'cmake', '.',
|
||||||
'-GUnix Makefiles',
|
'-GUnix Makefiles',
|
||||||
|
@ -86,12 +92,6 @@ def main(library_build_dir: str):
|
||||||
os.mkdir(build_dir)
|
os.mkdir(build_dir)
|
||||||
os.chdir(build_dir)
|
os.chdir(build_dir)
|
||||||
|
|
||||||
if in_psa_crypto_repo:
|
|
||||||
crypto_lib_filename = \
|
|
||||||
library_build_dir + '/core/libpsacrypto.a'
|
|
||||||
else:
|
|
||||||
crypto_lib_filename = library_build_dir + '/library/libmbedcrypto.a'
|
|
||||||
|
|
||||||
extra_includes = (';{}/drivers/builtin/include'.format(mbedtls_dir)
|
extra_includes = (';{}/drivers/builtin/include'.format(mbedtls_dir)
|
||||||
if in_psa_crypto_repo else '')
|
if in_psa_crypto_repo else '')
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue