Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libcoz.so has trouble finding a C++ mangled symbol #181

Open
Rohit-Athavale opened this issue May 19, 2021 · 1 comment
Open

libcoz.so has trouble finding a C++ mangled symbol #181

Rohit-Athavale opened this issue May 19, 2021 · 1 comment

Comments

@Rohit-Athavale
Copy link

Small summary is I'm compiling ffmpeg(executable composed of various media/codec libraries) with coz.
I'm on Ubuntu 18.04.5 LTS with gcc version 9.3.0

I installed coz by make install after cloning the master branch from here.

./ffmpeg: symbol lookup error: /usr/local/bin/../lib/libcoz.so: undefined symbol: _ZNK3elf3elf11get_sectionERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

  1. $ ./ffmpeg --help works fine (it shows the help options)
  2. $ coz run --- ./ffmpeg --help
[coz_experiments/coz/libcoz/libcoz.cpp:100] bootstrapping coz
[coz_experiments/coz/libcoz/libcoz.cpp:128] Including MAIN, which is /coz_experiments/sources/2021_05_14_11_44_48/ffmpeg/ffmpeg

./ffmpeg: symbol lookup error: /usr/local/bin/../lib/libcoz.so: undefined symbol: _ZNK3elf3elf11get_sectionERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

I've created a C-wrapper for some custom C++ libraries (say libfoo.so) . At run time those libraries are loaded, and they may contain other C++ references. However, ffmpeg is a pure C based executable.

Could someone tell me how to proceed.

@Rohit-Athavale
Copy link
Author

ffmpeg (the executable is stripped of symbols, however ffmpeg_g contains symbols)

$ nm ffmpeg_g | grep __cxx1112basic_stringIcSt11char
               U _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_createERmm@@GLIBCXX_3.4.21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant