What might cause 'undefined symbol' for typeinfo when loading dynamic library built with C++11 enabled?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Our C++ application, that runs on Linux, links to dynamic libraries built
by us. When everything is built using gcc 7.3.0 with switch -std=c++98, the
libraries load ok. However, when I build everything without that switch
(i.e. with C++11) dlopen() reports an undefined symbol:

undefined symbol: _ZTIN8StarLibs7LinkSim2NR13StarOfdmGenNRE ( typeinfo for
StarLibs::LinkSim::NR::StarOfdmGenNR )

(The demangled symbol name is in brackets.)

What could cause missing typeinfo, which is apparently for the class?

The class has methods that return const. Also the class's header file
#includes another class's header file and that included class contains some
static const members. I tried declaring those members in a separate .cpp
file to allocate them storage (that recipe fixed a similar error in another
part of the code) but it did not fix this problem.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux