CW10 has me stumped -- set compile-time defines...

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

CW10 has me stumped -- set compile-time defines...

1,472 Views
RichTestardi
Senior Contributor II

Sorry to ask such a basic question, but how do I get CW10 to set certain #defines (with -D XXX) when building a project?

 

I've imported an old project and can't even find where they are set for that (though they are correctly set).

 

They aren't in the command line "advanced" options for the preprocessor even, though it seems I can set them there by hand.

 

Thanks.

 

-- Rich

Labels (1)
0 Kudos
Reply
5 Replies

1,124 Views
RichTestardi
Senior Contributor II

In case the question is not clear, here's the CW7.2 dialog I'm looking for the equivalent of in CW10...

 

When I import my project, these settings are preserved (both MCF52259 and STICKOS are defined when I build), but I can't find where they are in the IDE (or how I can change them).

 

Thanks.

 

0 Kudos
Reply

1,124 Views
BlackNight
NXP Employee
NXP Employee

Hello,

yes, this is missing in MCU10.1 (and should be present in 10.2).

But you can add any command line options with the 'Other flags' settings (see attached image).

 

BK

 

0 Kudos
Reply

1,124 Views
DrTune
Contributor I

Ha just looking for that.

Thanks BlackNight you are extremely helpful!

0 Kudos
Reply

1,124 Views
RichTestardi
Senior Contributor II

Does anyone know if this was fixed in 10.2?

 

I still can't find a way to do it other than "Other flags".

 

More importantly, if I import a project that had #defines from CW7, I can't find where the #defines are stored in CW10, so I can't edit them or delete them (they don't show up in "Other flags").

 

Yes, I can *add* to them with "Other flags", but that doesn't really help -- it makes import unusable for me.

 

Thanks.

 

-- Rich

0 Kudos
Reply

1,124 Views
RichTestardi
Senior Contributor II

Maybe I will answer my own question -- you can edit the *.prefix file!!!

 

It is still not available in the GUI, but at least it is editable -- and my guess is the *.prefix file must be checked into source control!

 

0 Kudos
Reply