[CMake] absolute include paths to resource compiler

Jesper Eskilson jesper.eskilson at iar.com
Thu Dec 4 09:26:57 EST 2008


>> Due to some weirdness in Visual Studio, I need to be able to give the
>> resource compiler an absolute path:
>> 
>>   rc ... -I${CMAKE_SOURCE_DIR}/include
>> 
>> If I put
>> 
>>   include_directories(${CMAKE_SOURCE_DIR}/include)
>> 
>> CMake converts the absolute path to a relative one.
>> 
>> 
>What is the weirdness?   It should work without a full path?

Building works, but the resource view in Visual Studio can for some
reason not locate the resource file (in
${CMAKE_SOURCE_DIR}/include). It seems as if Visual Studio does not
always expand relative paths the same way. The result is that we can't
edit our resource files in Visual Studio, since Visual Studio can't
find them.

-- 
/Jesper



More information about the CMake mailing list