cancel
Showing results for 
Search instead for 
Did you mean: 

Managing multiple configurations

Christophe Beugnet
Associate II

Originally a reply to this, but is a separate discussion.


I've been playing with build configurations, working set, etc, for a while.

I know it's Eclipse and CDT's fault, not STM's. But it's SOOOOOOOO confusing, and there must be a solution. So far, I've created "things", mostly empty, useless "things" : Build Targets, Working Sets, etc. None cause a build to behave as expected.

Which is : having multiple "thing" "target" "thingies", each one using its own linker script (and why not, later at some point, specific .h/.c files). And being able to build one, or another, to get different FWs, each one using its own FLASH ORIGIN settings. Better even would be : one build, multiple FWs, each one in its own folder using its own linker script.

What's behind : OTA. As far as I understood, the linker script is the only place where a FW get its boot address. So far, when I build a FW #2, flash it in the second flash bank, the MCU boots the FW #1 from the first flash bank as long as the linker script indicates

 

FLASH    (rx)    : ORIGIN = 0x08000000,   LENGTH = 512K

 

I have to build FW #1 with this ORIGIN, then change ORIGIN by hand, then build FW #2. And not forget to copy FW #1 before build FW #2.

There must be a way to automate such builds ?

3 REPLIES 3

To answer your question, "Would it be possible to set one specific linker script per Build Configuration?" here:

Yes.

The Linker script is specified here - it is subject to the Configuration setting:

AndrewNeil_0-1736956125208.png

 

Oh yes, thanks, that does the job.

Well, can I add another level ? Is it possible to launch several builds with one click ?

Not tried it myself, but:

AndrewNeil_0-1736957873288.png

I think this is all standard Eclipse stuff - so googling for general Eclipse documentation etc would probably be worthwhile...

 

PS:

The 'Build Selected...' goes to:

AndrewNeil_1-1736958010788.png