From fb3e1596cfd576d12c07765d4d29d5f0ed2f7a1a Mon Sep 17 00:00:00 2001 From: Ronald Cron Date: Fri, 21 Jun 2024 09:07:58 +0200 Subject: [PATCH] Adapt include dir paths in test_psa_compliance.py Signed-off-by: Ronald Cron --- tests/scripts/test_psa_compliance.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/tests/scripts/test_psa_compliance.py b/tests/scripts/test_psa_compliance.py index b500fe5b51..d4e4979890 100755 --- a/tests/scripts/test_psa_compliance.py +++ b/tests/scripts/test_psa_compliance.py @@ -73,9 +73,14 @@ def main(library_build_dir: str): os.mkdir(build_dir) os.chdir(build_dir) - extra_includes = (';{}/drivers/builtin/include'.format(root_dir) - if in_tf_psa_crypto_repo else - ';{}/tf-psa-crypto/include'.format(root_dir)) + # Temporary while the PSA compliance test suite is still run as part + # of Mbed TLS testing. When it is not the case anymore, the second case + # can be removed. + if in_tf_psa_crypto_repo: + extra_includes = ';{}/drivers/builtin/include'.format(root_dir) + elif os.path.isdir(os.path.join(root_dir, 'tf-psa-crypto')): + extra_includes = ';{}/tf-psa-crypto/include'.format(root_dir) + \ + (';{}/tf-psa-crypto/drivers/builtin/include'.format(root_dir)) #pylint: disable=bad-continuation subprocess.check_call([