2024-09-16 09:45 AM
Hello! Thank you for opening this post.
This is my first time to fully build the Distribution Package according to the guide on ST Wiki, and I have gained a lot from it.
But now I have a question to ask for help. After I burned the generated image after the complete build, I found that the compilation date obtained by the uname -a command was incorrect. It was not around the current date, but Fri Mar 15 18:27:50 UTC 2024. What is the reason? I did not modify any code in this process. I think the build is to fully compile all components including the kernel. I hope to get an answer.
Thank you ST!
Solved! Go to Solution.
2024-09-16 11:29 PM
Hi @QinWei
I'm not expert, but this is usually because 'compilation date/time' is defined somewhere in a configuration file and not using 'current' compilation time.
The rationale of not using the 'current' system time is linked to quality requirements. In a company, this allows to confirm that even few year later you could build same binary (e.g. by checking Hash) whenever you extract sources with a defined tag from a configuration management system (e.g. git).
On my side, I don't know where this 'time' is defined, but if you wish/need to modify it, you could probably find it by yourself.
Regards.
2024-09-16 11:29 PM
Hi @QinWei
I'm not expert, but this is usually because 'compilation date/time' is defined somewhere in a configuration file and not using 'current' compilation time.
The rationale of not using the 'current' system time is linked to quality requirements. In a company, this allows to confirm that even few year later you could build same binary (e.g. by checking Hash) whenever you extract sources with a defined tag from a configuration management system (e.g. git).
On my side, I don't know where this 'time' is defined, but if you wish/need to modify it, you could probably find it by yourself.
Regards.
2024-09-17 06:01 AM
Thank you, thank you very much for your reply because this is my first time asking in the STM32 official community! !<3
I roughly understand what you mean, it sounds very reasonable, especially for checking the kernel version through the uname command. I found a similar question on the Internet:
:backhand_index_pointing_right:https://adaptivesupport.amd.com/s/article/76559?language=en_US:backhand_index_pointing_left:
And I found the REPRODUCIBLE_TIMESTAMP_ROOTFS keyword under my Yocto build path. I want to determine whether the value of this keyword affects the compilation time obtained by my uname, and I found that not only the compilation time of uname is incorrect, but also the default time of the system is incorrect. Looking forward to your professional reply, thank you! !