Ashwin Chandra wrote:
Notice the pdb file changed in case. I think what is happening is that the compiler is generating the pdb file in all lower case on the first build run and when doing a second build run, it somehow knows the file is in lowercase now and it updates the build.make files (which in turn tells cmake and visual studio compiler to do the linking phase over again). Note that a third or more builds work fine (no relinking).
Good analysis.
Is there anyway to have the build.make file always generate the pdb section in lowercase? Where does it get the case of the file anyway?
CMake generates the rules using the case of the logical target name. However, most paths that CMake processes on Windows go through a "get actual case" function which tries to preserve the case of the file as seen on disk. The first time the file doesn't exist, so CMake just uses the case it intends. The second time the file does exist, so the "get actual case" works and switches the case. It's kind of the compiler's fault for not preserving the case it is given in the /Fd option, but it is up to CMake to deal with it. We'll have to be more careful about which paths go through the "get actual case" function. Only files that are inputs to the build should go through it, while files generated by the build should not. Please submit this here: http://www.cmake.org/Bug Thanks, -Brad _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
