[CMake] Extra include/lib paths - multiple entries

Yngve Inntjore Levinsen yngve.levinsen at gmail.com
Wed Nov 17 07:12:42 EST 2010


On Wednesday 17 November 2010 12:30:06 Adam J Richardson wrote:
> Hi list,
> 
> Is this a correct specification for multiple include/lib paths in
> environment variables? If not, what should I use instead? Sometimes it
> seems to work, other times not...
> 
>   CMAKE_INCLUDE_PATH=C:/Compilers/Includes;C:/Compilers/MinGW/include
>   CMAKE_LIBRARY_PATH=C:/Compilers/Libs;C:/Compilers/MinGW/lib
> 
> Thanks,
> Adam J Richardson
> 

Hi,

This is how I would write it:
INCLUDE_DIRECTORIES(C:/Compilers/Includes C:/Compilers/MinGW/include)
TARGET_LINK_LIBRARIES(<your binary file name> C:/Compilers/Libs C:/Compilers/MinGW/lib)

I mostly use *nix systems though, so I am not perfectly sure how to get it correct on Windows..

Cheers
Yngve


More information about the CMake mailing list