Dolphin, the GameCube and Wii emulator - Forums
Compiling Dolphin with clang on linux fails - Printable Version

+- Dolphin, the GameCube and Wii emulator - Forums (https://forums.dolphin-emu.org)
+-- Forum: Dolphin Emulator Discussion and Support (https://forums.dolphin-emu.org/Forum-dolphin-emulator-discussion-and-support)
+--- Forum: Support (https://forums.dolphin-emu.org/Forum-support)
+--- Thread: Compiling Dolphin with clang on linux fails (/Thread-compiling-dolphin-with-clang-on-linux-fails)



Compiling Dolphin with clang on linux fails - tobias6626 - 09-02-2018

It spits out the following error:

Code:
/usr/bin/ld: ../Core/CMakeFiles/core.dir/NetPlayClient.cpp.o: in function `NetPlay::NetPlayClient::Connect()':
NetPlayClient.cpp:(.text+0x11a0): undefined reference to `sf::Packet::operator<<(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x11af): undefined reference to `sf::Packet::operator<<(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x11c2): undefined reference to `sf::Packet::operator<<(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
/usr/bin/ld: ../Core/CMakeFiles/core.dir/NetPlayClient.cpp.o: in function `NetPlay::NetPlayClient::OnData(sf::Packet&)':
NetPlayClient.cpp:(.text+0x1b1e): undefined reference to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x1c0d): undefined reference to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x1f64): undefined reference to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x22b6): undefined reference to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)'
/usr/bin/ld: NetPlayClient.cpp:(.text+0x2977): undefined reference to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)'
/usr/bin/ld: ../Core/CMakeFiles/core.dir/NetPlayClient.cpp.o:NetPlayClient.cpp:(.text+0x298a): more undefined references to `sf::Packet::operator>>(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&)' follow
/usr/bin/ld: ../Core/CMakeFiles/core.dir/NetPlayClient.cpp.o: in function `NetPlay::NetPlayClient::SendChatMessage(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)':
NetPlayClient.cpp:(.text+0x60c0): undefined reference to `sf::Packet::operator<<(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
/usr/bin/ld: ../Core/CMakeFiles/core.dir/NetPlayClient.cpp.o: in function `void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, NetPlay::NetPlayClient::ComputeMD5(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)::$_6> >(void*)':
NetPlayClient.cpp:(.text+0x877e): undefined reference to `sf::Packet::operator<<(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
/usr/bin/ld: ../Core/CMakeFiles/core.dir/WiiUtils.cpp.o: in function `WiiUtils::OnlineSystemUpdater::GetSystemTitles()':
WiiUtils.cpp:(.text+0x1e69): undefined reference to `pugi::xml_document::save(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, char const*, unsigned int, pugi::xml_encoding) const'
clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation)

How can I solve this?


RE: Compiling Dolphin with clang on linux fails - JonnyH - 09-02-2018

Looks like you've built dolphin with a different compiler (or settings - like a different -std or -stdlib) than the pugixml and sfml libraries.

This looks like a system issue.