[CMake] "Cannot restore timestamp" error on Windows
Brad King
brad.king at kitware.com
Mon Apr 29 16:49:45 EDT 2013
On 04/29/2013 04:37 PM, Raffi Enficiaud wrote:
> - process 1 is accessing generate.stamp for reading
Nothing ever reads the file. Only its existence and modification
time matter.
> - process 2 is moving some "tmpfile" to generate.stamp -> race
The only race was for multiple processes simultaneously deciding
they need to create the (currently missing) file and then trying
to open the file for write at the same time. That race is gone
because replacement is now atomic.
> stampName += std::string(this->Makefile->GetProjectName())
CMake has a different meaning for "project" than .vcxproj so this
will still be the same name for all targets in a directory. Each
.vcxproj file corresponds to what CMake calls a "target".
In order to use a different stamp file for each .vcxproj file then
the custom command produced by CreateVCProjBuildRule would not be
able to be re-used across multiple targets. Instead each generator
would have to hand-code the custom command for its own .vcxproj file.
While possible it is a lot of work and this bug has already been
solved.
-Brad
More information about the CMake
mailing list