std::basic_stringstream undefined linktime error with static library #4153
Unanswered
vsabavat
asked this question in
Community Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am trying to link with the static library of libgtest.a and running into an issue where the applicable is not able to compile and link successfully due to the following errors.
../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::internal::DeathTestImpl::Passed(bool)': gtest-all.cc:(.text+0x187e): undefined reference to
std::__cxx11::basic_ostringstream<char, std::char_traits, std::allocator >::basic_ostringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::Message::Message()': gtest-all.cc:(.text+0xdb16): undefined reference to
std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::internal::edit_distance::CreateUnifiedDiff(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, unsigned long)': gtest-all.cc:(.text+0xeed4): undefined reference to
std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::internal::WideStringToUtf8[abi:cxx11](wchar_t const*, int)': gtest-all.cc:(.text+0x10bb4): undefined reference to
std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::internal::String::FormatIntWidthN[abi:cxx11](int, int)': gtest-all.cc:(.text+0x11359): undefined reference to
std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o): In function
testing::internal::String::FormatHexUInt32[abi:cxx11](unsigned int)': gtest-all.cc:(.text+0x11455): undefined reference to
std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()'../../../_build/target-deps/gtest/lib/libgtest.a(gtest-all.cc.o):gtest-all.cc:(.text+0x1158f): more undefined references to `std::__cxx11::basic_stringstream<char, std::char_traits, std::allocator >::basic_stringstream()' follow
Beta Was this translation helpful? Give feedback.
All reactions