Please refer to the Secure Image project template available at the following location: "C:\Program Files (x86)\Cypress\PDL\3.x.x\security\secure_image"
Inside this directory, you will find a scripts directory where there are several bat files.
For example, the "secure_image_postbuild.bat" is designed to designed to run after the CM0+ application link step. It performs the following functions:
- Run the cymcuelftool to export select symbols (as defined in cy_si_export_symbols.txt) to be referenced by the user application.
- Run the cymcuelftool application signing process for creating a digital signature of the secure image.
Then the file "user_app0_postbuild.bat" is designed to run after the CM4 application link step. The script performs the following functions:
- Run the cymcuelftool application signing process for creating a digital signature of the user application image.
- Combine the user application image with the secure image to create a single elf file and a single hex file.
You could use these scripts for getting started and create your own bat scripts for your application. You can learn more about the project here: https://www.cypress.com/file/447981/download