public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Link problems
@ 2002-08-08  6:20 Jarmo
  2002-08-08  6:45 ` bjorn rohde jensen
  0 siblings, 1 reply; 4+ messages in thread
From: Jarmo @ 2002-08-08  6:20 UTC (permalink / raw)
  To: gcc-help

Hi,

I am developping application called MathPlanner. It is created with gcc 2.96 
and is working ok. Same days ago I installed gcc 3.0.4 from my linux 
distribution disk. MathPlanner compiles with no errors or warnings. But it is 
unable to link.   It does not find symbols from shared library libqt-mt.

lot of these  "undefined reference to QObject::"  

Do I have to rebuild every depending library with gcc 3.0.4 or what is wrong ?


Best regards,
Jarmo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Link problems
  2002-08-08  6:20 Link problems Jarmo
@ 2002-08-08  6:45 ` bjorn rohde jensen
  2002-08-08  9:08   ` Oscar Fuentes
  0 siblings, 1 reply; 4+ messages in thread
From: bjorn rohde jensen @ 2002-08-08  6:45 UTC (permalink / raw)
  To: Jarmo; +Cc: gcc-help

Hi Jarmo,

 You can not in general crosslink object code generated by
different compilers. You should use one and only one
compiler to create an application. One does usually not
have to rebuild the system C libraries, but C++ libs etc
definitely should be.
 The unresolved symbols are probably due to different
name mangling schemes employed by gcc-2.96, which is not
actually an official gcc release, and gcc-3.0.4. This is
done to protect users from linking incompatible object
files to create applications with spectacularly odd behaviour,
such as random core dumps despite code correctness and so on.

Yours sincerely,

Bjorn

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Link problems
  2002-08-08  6:45 ` bjorn rohde jensen
@ 2002-08-08  9:08   ` Oscar Fuentes
  2002-08-08  9:39     ` bjorn rohde jensen
  0 siblings, 1 reply; 4+ messages in thread
From: Oscar Fuentes @ 2002-08-08  9:08 UTC (permalink / raw)
  To: gcc-help

bjorn rohde jensen <bjensen@fastmail.fm> writes:

> Hi Jarmo,
> 
>  You can not in general crosslink object code generated by
> different compilers. You should use one and only one
> compiler to create an application. One does usually not
> have to rebuild the system C libraries, but C++ libs etc
> definitely should be.
>  The unresolved symbols are probably due to different
> name mangling schemes employed by gcc-2.96, which is not
> actually an official gcc release, and gcc-3.0.4. This is
> done to protect users from linking incompatible object
> files to create applications with spectacularly odd behaviour,
> such as random core dumps despite code correctness and so on.

Actually, that incompatibility among gcc 2.9x and gcc 3.x comes from
the introduction of a new "standard" C++ ABI on the gcc 3.x
series. One of the main goals of the new ABI is to allow the
interchange of object code among different C++ compilers which use
said ABI.

-- 
Oscar


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Link problems
  2002-08-08  9:08   ` Oscar Fuentes
@ 2002-08-08  9:39     ` bjorn rohde jensen
  0 siblings, 0 replies; 4+ messages in thread
From: bjorn rohde jensen @ 2002-08-08  9:39 UTC (permalink / raw)
  To: Oscar Fuentes; +Cc: gcc-help

Hi Oscar,

 Well, i did say generally. Object file compatibility
does fall outside the C++ specs to my limited knowledge,
it is a gcc extension. One has to be carefull about this
sort of thing though, try searching gcc.gnu.org for info
on the ABI, things are far from compatible at the moment.

Yours sincerely,

Bjorn

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-08-08 16:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-08  6:20 Link problems Jarmo
2002-08-08  6:45 ` bjorn rohde jensen
2002-08-08  9:08   ` Oscar Fuentes
2002-08-08  9:39     ` bjorn rohde jensen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).