Link time build error with new ThreadPool code #9
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Todays test build on the ARM machine has highlighted a link time error for multiple definition of CaveGame::Client::ThreadPool::Start()'; probably introduced with yesterdays checkin of the Client ThreadPool class for AsyncChunkRender check in.
[ 91%] Linking CXX shared library libCaveClient.so
/usr/bin/ld: CMakeFiles/CaveClient.dir/src/Client/LocalWorld.cpp.o: in function
CaveGame::Client::ThreadPool::Start()': LocalWorld.cpp:(.text+0x3f8): multiple definition of
CaveGame::Client::ThreadPool::Start()'; CMakeFiles/CaveClient.dir/src/Client/GameSession.cpp.o:GameSession.cpp:(.text+0x3f8): first defined here/usr/bin/ld: CMakeFiles/CaveClient.dir/src/Client/LocalWorld.cpp.o: in function
CaveGame::Client::ThreadPool::ThreadLoop()': LocalWorld.cpp:(.text+0x560): multiple definition of
CaveGame::Client::ThreadPool::ThreadLoop()'; CMakeFiles/CaveClient.dir/src/Client/GameSession.cpp.o:GameSession.cpp:(.text+0x560): first defined here/usr/bin/ld: CMakeFiles/CaveClient.dir/src/Client/LocalWorld.cpp.o: in function
CaveGame::Client::ThreadPool::QueueJob(std::function<void ()> const&)': LocalWorld.cpp:(.text+0x6b4): multiple definition of
CaveGame::Client::ThreadPool::QueueJob(std::function<void ()> const&)'; CMakeFiles/CaveClient.dir/src/Client/GameSession.cpp.o:GameSession.cpp:(.text+0x6b4): first defined here/usr/bin/ld: CMakeFiles/CaveClient.dir/src/Client/LocalWorld.cpp.o: in function
CaveGame::Client::ThreadPool::busy()': LocalWorld.cpp:(.text+0x784): multiple definition of
CaveGame::Client::ThreadPool::busy()'; CMakeFiles/CaveClient.dir/src/Client/GameSession.cpp.o:GameSession.cpp:(.text+0x784): first defined here/usr/bin/ld: CMakeFiles/CaveClient.dir/src/Client/LocalWorld.cpp.o: in function
CaveGame::Client::ThreadPool::Stop()': LocalWorld.cpp:(.text+0x810): multiple definition of
CaveGame::Client::ThreadPool::Stop()'; CMakeFiles/CaveClient.dir/src/Client/GameSession.cpp.o:GameSession.cpp:(.text+0x810): first defined herecollect2: error: ld returned 1 exit status
make[2]: *** [Client/CMakeFiles/CaveClient.dir/build.make:285: Client/libCaveClient.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:1002: Client/CMakeFiles/CaveClient.dir/all] Error 2
make: *** [Makefile:136: all] Error 2
Today it builds fine, so, closing this case. Thank you if you fixed something and apologies if this was my mistake. Builds correctly on Ubuntu 24.04 GCC 14 on AMD and ARM.