undefined reference to `liboai::Conversation::Conversation()' #54
lxj123-abc
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When I run the code in the diagram, I get an error:
/usr/bin/ld: robot.cpp:(.text+0x173c): undefined reference to
liboai::Conversation::AddUserData(std::basic_string_view<char, std::char_traits<char> >) &' /usr/bin/ld: robot.cpp:(.text+0x177b): undefined reference to
liboai::Authorization::SetKeyEnv(std::basic_string_view<char, std::char_traits >)'/usr/bin/ld: robot.cpp:(.text+0x18ed): undefined reference to
liboai::ChatCompletion::create(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, liboai::Conversation&, std::optional<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::optional<float>, std::optional<float>, std::optional<unsigned short>, std::optional<std::function<bool (std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, long, liboai::Conversation&)> >, std::optional<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> > > > >, std::optional<unsigned short>, std::optional<float>, std::optional<float>, std::optional<std::unordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, signed char, std::hash<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::equal_to<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const, signed char> > > >, std::optional<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >) const &' /usr/bin/ld: robot.cpp:(.text+0x1973): undefined reference to
liboai::Conversation::Update(liboai::Response const&) &'/usr/bin/ld: robot.cpp:(.text+0x1992): undefined reference to
liboai::Conversation::GetLastResponse[abi:cxx11]() const &' /usr/bin/ld: CMakeFiles/robot.dir/src/robot.cpp.o: in function
liboai::Authorization::Authorizer()':robot.cpp:(.text._ZN6liboai13Authorization10AuthorizerEv[_ZN6liboai13Authorization10AuthorizerEv]+0x4a): undefined reference to
liboai::Authorization::~Authorization()' /usr/bin/ld: CMakeFiles/robot.dir/src/robot.cpp.o: in function
std::pair<std::__cxx11::basic_string<char, std::char_traits, std::allocator > const, liboai::netimpl::components::EncodedAuthentication>::~pair()':robot.cpp:(.text._ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN6liboai7netimpl10components21EncodedAuthenticationEED2Ev[_ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN6liboai7netimpl10components21EncodedAuthenticationEED5Ev]+0x1c): undefined reference to `liboai::netimpl::components::EncodedAuthentication::~EncodedAuthentication()'
How can I solve this tricky problem that has been bothering me for two days?,thank you!
Beta Was this translation helpful? Give feedback.
All reactions