View Single Post
Old 2020-12-08, 21:47   #1
bsquared
 
bsquared's Avatar
 
"Ben"
Feb 2007

2×32×191 Posts
Default gcc 10.2.0 behavior

A couple times now I have seen reports where gcc 10.2.0 failed to compile a project that older gcc versions (and icc) compiled just fine. They fail with errors in the linking stage; complaining about multiple definitions of global constants defined in headers (e.g., see here).

I know that global definitions in headers is poor form, but it will be a pain to fix if that is the only solution going forward. The headers are all protected from being included twice using the usual #ifndef X #define X macros, which have worked up until now.

Any thoughts on fixes, or ideas about what happened with this newer gcc version?
bsquared is offline   Reply With Quote