cmake/Tests/RunCMake/ObjectLibrary/check_object_files.cmake
2019-11-11 23:01:05 +01:00

18 lines
398 B
CMake

if (NOT TARGET_OBJECTS)
message(SEND_ERROR "Object not passed as -DTARGET_OBJECTS")
endif()
foreach(objlib_file IN LISTS objects)
message(STATUS "objlib_file: =${objlib_file}=")
set(file_exists False)
if (EXISTS "${objlib_file}")
set(file_exists True)
endif()
if (NOT file_exists)
message(SEND_ERROR "File \"${objlib_file}\" does not exist!${tried}")
endif()
endforeach()