[plug] C++ errors

James Devenish devenish at guild.uwa.edu.au
Sun Jun 1 17:50:40 WST 2003


In message <1054449507.10200.12.camel at abbey>
on Sun, Jun 01, 2003 at 02:38:31PM +0800, Andrew Pamment wrote:
> I am writing a KDE application and am having some problems the first
> problem is it doesn't work.

With the proviso that I have no KDE experience...

> I keep getting an error from ld when I try
> and compile.

Oops...your mailer performed "line wrapping" on your ld output!!
I have pseudo-"unwrapped" the lines in my reply, for the sake of
argument^Willustration ;) I might not have done it right, though.

> generaloptions.o(.text+0x0): In function `generalOptions::generalOptions[not-in-charge](QWidget*, char const*, unsigned)':
> : multiple definition of `generalOptions::generalOptions[not-in-charge](QWidget*, char const*, unsigned)'
> generaloptions.o(.text+0x0): first defined here
> generaloptions.o(.text+0xcf4): In function `generalOptions::languageChange()':
> : multiple definition of `generalOptions::languageChange()'
> generaloptions.o(.text+0xcf4): first defined here

I haven't encountered this recently (or at all?) so I have to
guess. You know what, at first glance I would say "where are the other
lines"? I don't recognise the ':' followed by ':' motif, no why 'first
defined here' doesn't have something more well-phrased appearing after
it? Did you upgrade compiler / KDE in the middle of your development?
Could this be due to some inability of the compiler to resolve names
properly?

> my other problem is a gentoo specific one. I upgraded my compiler half
> way through writing my program and whenever I try to compile it tries to
> link to the old gcc libraries which dont exist anymore.

Have you got any diagnostic messages to go with that? One possible
explanation is that you have old linked libraries in your development
tree. It only takes on of them to have a reference to the old libraries
and you will have trouble. Can you `make clean` to delete the old
object files and recompile everything from scratch?




More information about the plug mailing list