CMake/Tests/Module/ExternalData/DataNoSymlinks/DataNoSymlinksCheck.cmake
Brad King 0de47b05f7 ExternalData: Add option to disable use of symlinks
Add an ExternalData_NO_SYMLINKS to enable use of copies instead of
symlinks to populate the real data files behind a DATA{} reference.
This will be useful on UNIX-like systems when the underlying filesystem
does not actually support symbolic links.

Suggested-by: Matt McCormick <matt.mccormick@kitware.com>
2015-05-22 09:21:47 -04:00

7 lines
210 B
CMake

if(NOT EXISTS "${Data}")
message(SEND_ERROR "Input file:\n ${Data}\ndoes not exist!")
endif()
if(IS_SYMLINK "${Data}")
message(SEND_ERROR "Input file:\n ${Data}\nis a symlink but should not be!")
endif()