generate_test_cert_macros.py: Removed absolute path from the rendered output #313

Open
minosgalanakis wants to merge 1 commit from minosgalanakis/tools/fix-auto-generated-files into main
minosgalanakis commented 2026-07-09 09:31:17 -05:00 (Migrated from github.com)

Description

As part of the post release activities, fixing minor inconveniences of the tooling required to build a release.

This pr adjust the generate_test_cert_macros.py logic to use relative paths BEFORE rendering the templates for the auto-generated files but continue using absolute paths internally so it can be called from different locations in the tree.

Needs to be tested locally with ./framework/scripts/generate_test_cert_macros.py and inspection of the header files.

PR checklist

Please add the numbers (or links) of the associated pull requests for consuming branches. You can omit branches where this pull request is not needed.

  • TF-PSA-Crypto development PR not required because: script contained here
  • TF-PSA-Crypto 1.1 PR not required because: script contained here
  • mbedtls development PR not required because: script contained here
  • mbedtls 4.1 PR not required because: script contained here
  • mbedtls 3.6 PR not required because: script contained here
## Description As part of the post release activities, fixing minor inconveniences of the tooling required to build a release. This pr adjust the generate_test_cert_macros.py logic to use relative paths BEFORE rendering the templates for the auto-generated files but continue using absolute paths internally so it can be called from different locations in the tree. Needs to be tested locally with `./framework/scripts/generate_test_cert_macros.py` and inspection of the header files. ## PR checklist Please add the numbers (or links) of the associated pull requests for consuming branches. You can omit branches where this pull request is not needed. - [ ] **TF-PSA-Crypto development PR** not required because: script contained here - [ ] **TF-PSA-Crypto 1.1 PR** not required because: script contained here - [ ] **mbedtls development PR** not required because: script contained here - [ ] **mbedtls 4.1 PR** not required because: script contained here - [ ] **mbedtls 3.6 PR** not required because: script contained here
ronald-cron-arm (Migrated from github.com) reviewed 2026-07-09 09:31:17 -05:00
bjwtaylor (Migrated from github.com) approved these changes 2026-07-10 03:01:57 -05:00
bjwtaylor (Migrated from github.com) approved these changes 2026-07-10 03:02:44 -05:00
bjwtaylor (Migrated from github.com) left a comment

The changes look good but there is a ci failure that will need to be resolved.

The changes look good but there is a ci failure that will need to be resolved.
ronald-cron-arm commented 2026-07-10 03:08:01 -05:00 (Migrated from github.com)

Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py?

Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py?
ronald-cron-arm commented 2026-07-10 03:11:10 -05:00 (Migrated from github.com)

Otherwise could you clean-up the PR description? Remove the "Notes for the submitter", update the PR checklist.

Otherwise could you clean-up the PR description? Remove the "Notes for the submitter", update the PR checklist.
minosgalanakis commented 2026-07-10 04:09:04 -05:00 (Migrated from github.com)

Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py?

Because generate_test_cert_macros is called by make_generated_files, but yes you are right it could be more specific.

Also the CI failure is the typical intermitten ssl one, restarted

> Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py? Because generate_test_cert_macros is called by make_generated_files, but yes you are right it could be more specific. Also the CI failure is the typical intermitten ssl one, restarted
ronald-cron-arm commented 2026-07-10 04:34:39 -05:00 (Migrated from github.com)

Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py?

Because generate_test_cert_macros is called by make_generated_files, but yes you are right it could be more specific.

Please update the title and PR description accordingly.

> > Why do you mention make_generated_files.py here where it is about scripts/generate_test_cert_macros.py? > > Because generate_test_cert_macros is called by make_generated_files, but yes you are right it could be more specific. Please update the title and PR description accordingly.
ronald-cron-arm (Migrated from github.com) requested changes 2026-07-10 09:54:36 -05:00
ronald-cron-arm (Migrated from github.com) left a comment
See https://github.com/Mbed-TLS/mbedtls-framework/pull/313#issuecomment-4933987792
gilles-peskine-arm (Migrated from github.com) requested changes 2026-07-23 08:32:11 -05:00
gilles-peskine-arm (Migrated from github.com) left a comment

There is already a fix for that in https://github.com/Mbed-TLS/mbedtls-framework/pull/231. Let's not spend more time making a second one.

There is already a fix for that in https://github.com/Mbed-TLS/mbedtls-framework/pull/231. Let's not spend more time making a second one.
This pull request has changes conflicting with the target branch.
  • scripts/generate_test_cert_macros.py
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'minosgalanakis/tools/fix-auto-generated-files:minosgalanakis/tools/fix-auto-generated-files'
git switch 'minosgalanakis/tools/fix-auto-generated-files'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'minosgalanakis/tools/fix-auto-generated-files'
git switch 'minosgalanakis/tools/fix-auto-generated-files'
git rebase 'main'
git switch 'main'
git merge --ff-only 'minosgalanakis/tools/fix-auto-generated-files'
git switch 'minosgalanakis/tools/fix-auto-generated-files'
git rebase 'main'
git switch 'main'
git merge --no-ff 'minosgalanakis/tools/fix-auto-generated-files'
git switch 'main'
git merge --squash 'minosgalanakis/tools/fix-auto-generated-files'
git switch 'main'
git merge --ff-only 'minosgalanakis/tools/fix-auto-generated-files'
git switch 'main'
git merge 'minosgalanakis/tools/fix-auto-generated-files'
git push origin 'main'
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-Mbed-TLS/mbedtls-framework!313
No description provided.