public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Using DLLs created with different compilers
@ 2003-03-07 23:02 Singh, Diwakar V
  2003-03-08  1:38 ` Janis Johnson
  0 siblings, 1 reply; 2+ messages in thread
From: Singh, Diwakar V @ 2003-03-07 23:02 UTC (permalink / raw)
  To: gcc

I have two different libraries - one compiled with GCC and another with
a different, old compiler in Unix environment. Both these have C++
classes defined in them. When I link these libraries to an application
program that I created, I get a link error. This is because the name
mangling scheme used by GCC is different from that used by the other
compiler. Is there any option available to set the name mangling scheme/
not enable the name mangling?

Thanks

Diwakar

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

* Re: Using DLLs created with different compilers
  2003-03-07 23:02 Using DLLs created with different compilers Singh, Diwakar V
@ 2003-03-08  1:38 ` Janis Johnson
  0 siblings, 0 replies; 2+ messages in thread
From: Janis Johnson @ 2003-03-08  1:38 UTC (permalink / raw)
  To: Singh, Diwakar V; +Cc: gcc

On Fri, Mar 07, 2003 at 03:23:06PM -0700, Singh, Diwakar V wrote:
> I have two different libraries - one compiled with GCC and another with
> a different, old compiler in Unix environment. Both these have C++
> classes defined in them. When I link these libraries to an application
> program that I created, I get a link error. This is because the name
> mangling scheme used by GCC is different from that used by the other
> compiler. Is there any option available to set the name mangling scheme/
> not enable the name mangling?

There's a lot that different besides name mangling.  Libraries compiled
by different C++ compilers can't be used together unless the compilers
both follow the same C++ ABI, and until recently there hasn't even been
a formal ABI for C++.

See http://gcc.gnu.org/onlinedocs/gcc/Compatibility.html#Compatibility
(part of the GCC Manual) for more information about this topic.

Janis

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

end of thread, other threads:[~2003-03-08  0:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-03-07 23:02 Using DLLs created with different compilers Singh, Diwakar V
2003-03-08  1:38 ` Janis Johnson

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).