cancel
Showing results for 
Search instead for 
Did you mean: 

How do we add custom project compiler options like -I, -D that are not overwritten each time you regenerate?

MMitc
Associate II

I'm using libraries from outside the project tree so I need to define symbols and add include directories. But every time I regenerate code with CubeMX, my additions are overwritten. Is there any place or method I can add to those options that won't be overwritten? If not this seems like a huge bug.

4 REPLIES 4
Cartu38 OpenDev
Lead II

Which IDE version are you relying on ?. Such was definitvely buggy BUT solved on my side Thanks 1.1.0 version

Markus GIRDLAND
ST Employee

I'll tag along with @Cartu38 OpenDev​ that this was an issue before version 1.1.0 but should be fixed by now.

If you're using 1.1.0 and you have a way to reproduce it then please let me know!

MMitc
Associate II

Still having the issue on 1.1.10.

For anyone else having this issue, a workaround is to export the project settings to a file, then import them after regeneration.

@Markus GIRDLAND​ I sent sample files privately.

I just downloaded the project and did some testing but I can't seem to reproduce it.

I can add my own symbols, include paths and compiler options and then regenerate the project and they're still there for me.

Not sure if there are some additional steps I need to do in order to recreate it.