You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
739 B

set(vcProjectFile "${RunCMake_TEST_BINARY_DIR}/foo.vcxproj")
if(NOT EXISTS "${vcProjectFile}")
set(RunCMake_TEST_FAILED "Project file ${vcProjectFile} does not exist.")
return()
endif()
set(found_ImportLibrary 0)
set(found_TargetExt_dll 0)
file(STRINGS "${vcProjectFile}" lines)
foreach(line IN LISTS lines)
if(line MATCHES "<ImportLibrary>")
set(found_ImportLibrary 1)
endif()
if(line MATCHES "<TargetExt[^\n]*\\.dll")
set(found_TargetExt_dll 1)
endif()
endforeach()
if(found_ImportLibrary)
string(APPEND RunCMake_TEST_FAILED "ImportLibrary incorrectly found in\n ${vcProjectFile}\n")
endif()
if(NOT found_TargetExt_dll)
string(APPEND RunCMake_TEST_FAILED "TargetExt not found in\n ${vcProjectFile}\n")
endif()