Generating demangled C++ object files -- Guru's Needed For this one!!!!

Generating demangled C++ object files -- Guru's Needed For this one!!!!

Post by Decker, Christian » Fri, 28 May 1999 04:00:00



Does anyone know how, or even if it is possible, to compile a C++ file so
that the object file generated contains
demangled symbols for function names?

I need to do this because I am trying to link an Ada program with a C++
object file and the Ada linker can not
resolve the imported function because the C++ object file contains mangled
function names.

If one can't produce a demangled object file, does anyone know a
compiler/linker switch that i could pass to the
Ada compiler so that it can resolve names from a C++ object file?

This is a tough one!!
Thanks for any help!
Chris Decker

   -**** Posted from RemarQ, http://www.remarq.com/?a ****-
 Search and Read Usenet Discussions in your Browser - FREE -

 
 
 

Generating demangled C++ object files -- Guru's Needed For this one!!!!

Post by Andrew Giert » Fri, 28 May 1999 04:00:00


 Decker> Does anyone know how, or even if it is possible, to compile a
 Decker> C++ file so that the object file generated contains demangled
 Decker> symbols for function names?

Declare all the functions you are exporting as being extern "C".

--
Andrew.

comp.unix.programmer FAQ: see <URL: http://www.erlenstar.demon.co.uk/unix/>
                           or <URL: http://www.whitefang.com/unix/>

 
 
 

1. how to make one object file from several object files

I am developing a network driver.

And I need only one object file to setup module.

But I have several source.

examples about make file)

hwmain.o: hwmain.o hwfpga.o                        ----> I don't want to
link. I only need one object file from hwmain.o and hwfpga.o
 gcc -c hwmain.o hwmain.o hwfpga.o

hwmain.o:hwmain.c
 gcc -c hwmain.c -O2 -Wall -Wstrict-prototypes \
               -fomit-frame-pointer \
        -fno-strength-reduce -pipe -m486 -malign-loops=2 \
        -malign-jumps=2 -malign-functions=2 -DCPU=486 \
        -DMODULE -D__KERNEL__

hwfpga.o:source/hwfpga.c
 gcc -c source/hwfpga.c -O2 -Wall -Wstrict-prototypes \
               -fomit-frame-pointer \
        -fno-strength-reduce -pipe -m486 -malign-loops=2 \
        -malign-jumps=2 -malign-functions=2 -DCPU=486 \
        -DMODULE -D__KERNEL__

2. Linux as an entertainment center

3. header files needed if object files are available in C++ ?

4. Physical Memory Allocation?

5. Linking C and C++ code object files with 'ld'?

6. Weird response from 'host' command

7. c++ IDE like Microsoft's Visual C++, is there one

8. chmod question

9. gcc doesn't generate object for string template

10. Here's a good one for Guru's!

11. Here's a tough one for all you guru's

12. 'cannot demangle' error

13. Demangling C++ class/function names for shared libraries