[CMake] link : shared libraries into executable
Mike Jackson
mike.jackson at imts.us
Thu Jun 26 07:55:27 EDT 2008
Target_link_Libraries (Executable pthread rt dl nsl)
If those libraries are in the standard locations gcc should be able
to pick them up ok.
--
Mike Jackson Senior Research Engineer
Innovative Management & Technology Services
On Jun 26, 2008, at 5:44 AM, Ingrid Kemgoum wrote:
> hi, i'm building a unix project.
> i want to add "-lpthread -lrt -ldl -lnsl" to all executables.
> when i use set_target_prop with link_flags, those lib are placed
> right after the compile flags.
> when i use set(cmake_standard-libraries libpthread.so ...) nothing
> happen i don't even know where this command has an effect.
>
> My problem is that in unix we have order in librairies and i want
> those at the end for all my executables.
> i've tested adding libpthread.so at the end in target_link_libraries
> (..) for one of my executables and everythink goes well.
>
> what can i do to fix this first to be set in link options for my
> executables?
>
> i don't know if i'm clear but thanks for help
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20080626/650c2f81/attachment.htm>
More information about the CMake
mailing list