[CMake] idea for shorter linker commands
Alexander Neundorf
a.neundorf-work at gmx.net
Wed Nov 23 15:59:56 EST 2005
Hi,
recently I read that you are trying to reduce the length of the required
linker commands.
How about executing the linker command from the directory, where the
object files are located, instead of executing it from the top directory,
i.e.
cd CMakeFiles/test.dir && c++ -fPIC "main.o" "foo.o" -o ../../test
-rdynamic
instead of:
c++ -fPIC "CMakeFiles/test.dir/main.o" "CMakeFiles/test.dir/foo.o" -o
test -rdynamic
This would work even better if the object files would again all be
located in one directory, and not distributed in subdirectories arranged
parallel to the subdirectories of the source files ?
Bye
Alex
--
Telefonieren Sie schon oder sparen Sie noch?
NEU: GMX Phone_Flat http://www.gmx.net/de/go/telefonie
More information about the CMake
mailing list