You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On ububntu there is a weird error when you try to actually link a c++ program against nuflux. The linking step works perfectly in the meson testing environment and all the tests pass but when linking another program you get:
/usr/bin/ld: /tmp/ccyWsns7.o: in function `main':
test_basic.cxx:(.text+0x28): undefined reference to `nuflux::availableFluxes[abi:cxx11]()'
/usr/bin/ld: test_basic.cxx:(.text+0x5b): undefined reference to `nuflux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
collect2: error: ld returned 1 exit status
The symbols are in the so file so i cant figure out why linking isn't working
# nm /usr/local/lib/x86_64-linux-gnu/libnuflux.so|grep 'availableFluxes\|makeFlux'|c++filt
000000000002c990 T nuflux::SplineFlux2::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
0000000000030510 T nuflux::availableFluxes[abi:cxx11]()
0000000000014a5a t nuflux::availableFluxes[abi:cxx11]() [clone .cold]
0000000000033480 T nuflux::LegacyPromptFlux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
0000000000027f40 T nuflux::SimpleSplineFlux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
0000000000020730 T nuflux::IntegralPreservingFlux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
00000000000263d0 T nuflux::LegacyConventionalFlux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
0000000000019840 T nuflux::ANFlux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
000000000002faf0 T nuflux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
000000000001487c t nuflux::makeFlux(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) [clone .cold]
On ububntu there is a weird error when you try to actually link a c++ program against nuflux. The linking step works perfectly in the meson testing environment and all the tests pass but when linking another program you get:
The symbols are in the so file so i cant figure out why linking isn't working
This can be reproduced in a docker image:
The text was updated successfully, but these errors were encountered: