[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: help with C API in C++ static library
From: |
Jason Kraftcheck |
Subject: |
Re: help with C API in C++ static library |
Date: |
Fri, 15 Jan 2010 14:19:01 -0600 |
User-agent: |
Mozilla-Thunderbird 2.0.0.22 (X11/20090707) |
Harring Figueiredo wrote:
> Was the C API code explicilty marked as C so that the compiler does not
> mangle the fucntion names? Check to make sure this is not happening.
>
Thanks for taking the time to reply. Unfortunately, the problem isn't this
simple. I have marked the function names as 'extern "C"' in the C++ source.
The problem is finding symbols that are in the C++ runtime librariy (e.g.
libstdc++), not my library. Some examples:
: undefined reference to `std::cerr'
: undefined reference to `std::basic_ostream<char, std::char_traits<char> >&
std::__ostream_insert<char, std::char_traits<char>>(std::basic_ostream<char,
std::char_traits<char> >&, char const*, long)'
thanks,
- jason