Page MenuHomePhabricator

Secure image (tfm_s.hex) output directory is not constant
Open, NormalPublic


When compile with the configuration (ConfigXXX.cmake) that has CORE_TEST enabled.
The output directory of secure image (tfm_s.hex) would be changed to unit_test (secure_fw/CMakeLists.txt).
e.g.: <build>/unit_test/tfm_s.*

This behaviour causing problem in build procedure (and CI). Extra scripts is needed to find where the image is, to sign/flash it. And there is no clue (as CORE_TEST is a internal variable in each configuration file that could be enabled/disabled) for the script to know ahead where the output image would be.

Which also introduce hidden problem to engineer in developing stage, that s/he could not make incremental build, but having to clean & rebuild everything to make sure not to get the wrong image (generated from previous build), if s/he is modifying something that might change output directory.

Trace the commit, found that it was firstly introduced in

30fa9871a8 Build: Cmake build system

I didn't find the reason, or related info, that why it has to be put in different directory (unit_test).
If possible, please keep the output directory fixed (e.g.: SPE: secure_fw/; NSPE: app/) to make life easier.
(I like to have computer to help human to solve problem, not to generate problem :) )

Event Timeline

AlamyLiu triaged this task as Normal priority.Dec 13 2019, 2:09 AM
AlamyLiu created this task.