MantisBT - CMake
View Issue Details
0010281CMakeCMakepublic2010-02-12 12:382011-01-31 16:08
Jeremy Nicholl 
Brad King 
normalmajoralways
closedfixed 
CMake-2-8 
CMake 2.8.4CMake 2.8.4 
0010281: Include paths containing backslashes cause dependency failures
I'm using MSYS and I ran into an issue where one of my header files
has the line
#include "foo\bar.h" // Note backslash
In this case, the dependency that gets generated simply appends
"foo\bar.h" to a well-formed MSYS path with forward slashes, and that
seems to mean the file cannot be found.
See http://www.cmake.org/pipermail/cmake/2010-February/035139.html [^] for the initial discussion.

I was trying to work around the problem by creating a transform rule in CMAKE_INCLUDE_TRANSFORMS, but still having difficulty with it. I'll update this if I find a good workaround.
No tags attached.
Issue History
2010-02-12 12:38Jeremy NichollNew Issue
2011-01-17 13:35David ColeAssigned To => Brad King
2011-01-17 13:35David ColeStatusnew => assigned
2011-01-17 14:35Brad KingNote Added: 0024792
2011-01-17 15:15Brad KingNote Added: 0024801
2011-01-17 15:15Brad KingStatusassigned => closed
2011-01-17 15:15Brad KingResolutionopen => fixed
2011-01-31 16:08David ColeFixed in Version => CMake 2.8.4
2011-01-31 16:08David ColeTarget Version => CMake 2.8.4

Notes
(0024792)
Brad King   
2011-01-17 14:35   
I can reproduce the "/path/to/foo\bar.h" in depend.make but it does not actually cause any problems with MSYS make. The build completes and touching bar.h causes dependencies to rescan and the source to recompile.

Still, it makes sense to convert '\' -> '/' as preferred by the tools.
(0024801)
Brad King   
2011-01-17 15:15   
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=8dc7501d [^]