[CMake] how to link with a system library ?
eric.noulard at gmail.com
Sun Sep 21 06:38:04 EDT 2008
2008/9/21 Steven Samuel Cole <steven.samuel.cole at gmail.com>:
> I would like to link a system library into an executable, GTK in this case.
> What I'm trying to do is
> target_link_libraries(myexec $GTK_LIBRARIES)
> add_executable (myexec sources)
> CMake Error: Attempt to add link library "GTK_LIBRARIES" to target "myexec"
> which is not built by this project.
> What am I doing wrong ?
You may be missing curly brace around variable could you try:
More information about the CMake