cancel
Showing results for 
Search instead for 
Did you mean: 

pre-defined macro

yang hong
Associate II

Hello,

I would like to use #define macro in my program to hold application, firmware version and firmware building time.

I know i can put these definition into my program directly, and make modification before I compile my program.

Could I use GNU C to pass these macro when I compile my program? I know I can set some macro on path and symbols in properties for project. but I am not sure I can do it for the user-defined macro?

Thank you for any help!

1 REPLY 1
turboscrew
Senior III

I haven't done that, but I'd look into -D switch of the compiler...

Like -DVERSION=2