Hi Walt, Am Mittwoch, 10. August 2011, 16:16:50 schrieb walt: > On 08/10/2011 03:04 PM, Michael Schreckenbauer wrote: > > Hi, > > > > Am Mittwoch, 10. August 2011, 14:40:31 schrieb walt: > >> On 08/09/2011 08:34 PM, Jeff Cranmer wrote: > >>> Hi all, > >>> > >>> I'm trying to upgrade kde from 4.4 to 4.6, and I've run into a > >>> problem. > >>> > >>> Plasma-runtime-4.6.3 is failing. The error appears to be > >>> redefinition of 'struct QMetaTypeID<Plasma::Service*>' > >> > >> I don't use kde so I can't be specific, but usually a redefinition is > >> just a warning -- unless the package is compiled with the -Wall flag > >> or > >> equivalent. > > (Of course I meant -Werror, sorry.)
no prob. > > No, this is plain wrong. Redefinition of a struct is an error in C and > > C++ > > > > ~$cat foo.c > > struct foo { > > > > int i; > > > > }; > > > > struct foo { > > > > char* v; > > > > }; > > > > ~$gcc foo.c -o foo > > foo.c:5:8: error: redefinition of 'struct foo' > > foo.c:1:8: note: originally defined here > > Hm. I know I've seen compiler redefinition messages thousands of times > over the years. Is it really possible that all of those thousands were > errors instead of warnings? If that's true then I've wasted a lot more > time tracking them down than I care to think about :) struct redefinition is always an error. Maybe what you saw as a warning was some kind of macro redefined. ~ $ cat bar.c #define BAR 0 #define BAR 1 int main() { } ~$gcc bar.c -o bar bar.c:2:0: warning: "BAR" redefined bar.c:1:0: note: this is the location of the previous definition Note the different wording in the message. Regards, Michael