This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Compile same source code of Mesh-SDK-2.2, got different hex file

Hi Nordic:

I got a strange result, I compile a example of Mesh-sdk-2.2, such as proxy_client, then I copy proxy_client to another folder such as proxy_client_b and compile it.

Then I got two different hex files of proxy_client and proxy_client_b.

I've try to modify some target options such as "include debug information= no", "debugging level = none", "strip debug information=yes", "strip symbols=yes",

but still got two different hex file, I hope same source code can get same hex file, could you try to check if you have same issue? 

Regards,

Joseph

Parents
  • Hi,

    What compiler and toolchain are you using?

    Reproducibility of software builds is an interesting topic. Some things to watch out for are the paths of the source files, timestamp of the build, random values generated at compile time, multithreaded build process leading to different placement of functions, data, etc. in the final binary, and more.

    I do not have an overview of what factors change for our nRF5 SDK for mesh examples, and reproducibility is not a stated goal for our examples. It would however be interesting to see what is the difference between your hex files, just as  asked for. Then maybe we can provide some suggestions for what might cause that difference.

    Regards,
    Terje

  • Hi tesc:

    Thanks sharing the good knowledge of compiler, 

    After I set target option/compiler/supply absolute file path, then two folder's hex file are same, but I havn't check if this option will affect firmware behavior, thank you.

    Joseph

Reply Children
No Data
Related