[CMake] how to really change CMake linker
Mark Abraham
mark.j.abraham at gmail.com
Mon Aug 11 23:13:26 EDT 2014
Hi,
In order to build an application with several HPC performance utilities, it
would be good to be able to specify the linker and have it show up on the
link command line.
I learned from
http://cmake.3232098.n2.nabble.com/Specify-the-link-command-in-CMake-td6786695.html
that using CMAKE_C_LINKER_EXECUTABLE and CMAKE_CXX_LINKER_EXECUTABLE is not
the right approach, because you have to specify the entire link line, not
just the linker.
cmake -DCMAKE_LINKER=/path/to/my/linker seems like it should be the right
way to do this, yet the C++ compiler ends up on the link line, not the
linker I specified (which has a different name, of course).
http://stackoverflow.com/questions/1867745/cmake-use-a-custom-linker is
having the same experience.
How should this be accomplished reliably?
Thanks!
Mark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20140811/b1111c0a/attachment-0001.html>
More information about the CMake
mailing list