Hello CMakers,

I recently switched from CMake 2.8.12 to 3.8.2 and the behaviour of

file(TIMESTAMP MyFile MyFileTimestamp)

changed when MyFileis a symbolic link under Windows.

In 2.8.12 the funtion was reporting of the actual file timestamp pointed by
the symbolic link.
In 3.8.2 the funcitons returns the symbolic link itself timpestamp.

Has this behaviour changed intentionally? I do not find anything related in
the change logs.

Trying to workaround this issue, I stumbled upon get_filename_component
function which I can use to get the realpath of a symbolic link but when I
use it as:

get_filename_component(MyFileRealPath ${MyFile} REALPATH)

MyFileRealPath contains the symbolic link path, not the real path!. I am
currently digging in cmake source code and considering reporting as a bug.

Any comments will be warmly welcomed.

Regards!
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to