Hi, I posted about a week ago on a problem I had when linking quite a few object files together to an so on Linux (Ubuntu 12.04, running CodeBlocks 13.12, upgraded from 10.05 finally).
My link statement is this:
g++ -L../../../bin/Debug -o ../../../bin/Debug/Core.Test obj/Debug/src/CoreMutexTest.o obj/Debug/src/Main.o obj/Debug/src/CoreWorkerThreadTest.o obj/Debug/src/CoreTimerTest.o obj/Debug/src/CoreTimeStampTest.o obj/Debug/src/CoreThreadTest.o obj/Debug/src/CoreTextWriterTest.o obj/Debug/src/CoreTextReaderTest.o obj/Debug/src/CoreStreamTest.o obj/Debug/external/gtest/gtest-all.o obj/Debug/src/CoreManualEventTest.o obj/Debug/src/CoreCyclicBufferTest.o obj/Debug/src/CoreByteArrayTest.o obj/Debug/src/CoreAutoEventTest.o obj/Debug/src/CoreArrayTest.o obj/Debug/src/CoreActiveObjectTest.o -Wl,-rpath,'$ORIGIN' -lCore -lrt -lpthread
When building from a makefiles, this works perfectly. However, when I set the linker to echo instead of actually link in CodeBlocks, the output is:
g++ -L../../../bin/Debug -o ../../../bin/Debug/Core.Test obj/Debug/src/CoreMutexTest.o obj/Debug/src/Main.o obj/Debug/src/CoreWorkerThreadTest.o obj/Debug/src/CoreTimerTest.o obj/Debug/src/CoreTimeStampTest.o obj/Debug/src/CoreThreadTest.o obj/Debug/src/CoreTextWriterTest.o obj/Debug/src/CoreTextReaderTest.o obj/Debug/src/CoreStreamTest.o obj/Debug/external/gtest/gtest-all.o obj/Debug/src/CoreManualEventTest.o obj/Debug/src/CoreCyclicBufferTest.o obj/Debug/src/CoreByteArrayTest.o obj/Debug/src/CoreAutoEventTest.o obj/Debug/src/CoreArrayTest.o obj/Debug/src/CoreActiveObjectTest.o -Wl,-rpath,
This points to a chopping of of the command line. Does this sound familiar? I had the same problem with CB 10.05, but the upgrade to 13.12 does not seem to help.
This is really a pity, as I strongly prefer CB over Eclipse!
Regards,
Rene Barto