* [ECOS] ...porting software developed under cygwin with gcc to diab compiler...
@ 2001-02-05 4:47 luca.spinacci
2001-02-05 5:09 ` Bart Veer
0 siblings, 1 reply; 2+ messages in thread
From: luca.spinacci @ 2001-02-05 4:47 UTC (permalink / raw)
To: ecos-discuss
I'm working with a real time operative system (for Windows NT) whose compiler is
DIAB (cross compiler).
I' m trying to compile with the above a project developed, compiled and built
under cygwin with GCC compiler and link that project with an existing project
compiled under DIAB.
I haven't succeeded so far since there are C++ features (template functions in
template class...) that the DIAB compiler isn't able to solve.
I used eCOS on my PC and successfully compiled the imported project.
I tried to GCC compile those same files generating the assembly code and then to
build the project by means of DIAB.
Obviously I got linking problems due to different name mangling of GCC and DIAB.
I know name mangling is different on different compilers but it would be
helpful to know if GCC has compiler options to standardize its name mangling or
there's a standard follwed by some compilers.
Regards.
Spinacci Luca.
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [ECOS] ...porting software developed under cygwin with gcc to diab compiler...
2001-02-05 4:47 [ECOS] ...porting software developed under cygwin with gcc to diab compiler luca.spinacci
@ 2001-02-05 5:09 ` Bart Veer
0 siblings, 0 replies; 2+ messages in thread
From: Bart Veer @ 2001-02-05 5:09 UTC (permalink / raw)
To: luca.spinacci; +Cc: ecos-discuss
>>>>> "Luca" == luca spinacci <luca.spinacci@marconicomms.com> writes:
Luca> I'm working with a real time operative system (for Windows
Luca> NT) whose compiler is DIAB (cross compiler).
Luca> I' m trying to compile with the above a project developed,
Luca> compiled and built under cygwin with GCC compiler and link
Luca> that project with an existing project compiled under DIAB.
Luca> I haven't succeeded so far since there are C++ features
Luca> (template functions in template class...) that the DIAB
Luca> compiler isn't able to solve. I used eCOS on my PC and
Luca> successfully compiled the imported project. I tried to GCC
Luca> compile those same files generating the assembly code and
Luca> then to build the project by means of DIAB.
Luca> Obviously I got linking problems due to different name
Luca> mangling of GCC and DIAB. I know name mangling is different
Luca> on different compilers but it would be helpful to know if
Luca> GCC has compiler options to standardize its name mangling or
Luca> there's a standard follwed by some compilers.
There is no such compiler option, deliberately so. Traditionally the
code generated by different C++ compilers is incompatible in numerous
ways, e.g. layout of the virtual function table. Any attempt to mix
code generated by different compilers is pretty much doomed to
failure. The use of incompatible name mangling schemes acts as a
safety net, it ensures that you will get errors at link-time rather
than weird and undebuggable crashes at run-time.
There is work in progress on standardizing a C++ ABI for certain
platforms. On the g++ side this ABI should be supported when gcc 3.0
gets released, see http://gcc.gnu.org for more information.
Bart
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-02-05 5:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-02-05 4:47 [ECOS] ...porting software developed under cygwin with gcc to diab compiler luca.spinacci
2001-02-05 5:09 ` Bart Veer
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).