summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/GeneratorInstance/DefaultInstance.cmake
blob: 7750c2e14264f206a593fec51b99f5f1250ebb54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
if("x${CMAKE_GENERATOR_INSTANCE}" STREQUAL "x")
  message(FATAL_ERROR "CMAKE_GENERATOR_INSTANCE is empty but should have a value.")
elseif("x${CMAKE_GENERATOR_INSTANCE}" MATCHES [[\\]])
  message(FATAL_ERROR
    "CMAKE_GENERATOR_INSTANCE is\n"
    "  ${CMAKE_GENERATOR_INSTANCE}\n"
    "which contains a backslash.")
elseif(NOT IS_DIRECTORY "${CMAKE_GENERATOR_INSTANCE}")
  message(FATAL_ERROR
    "CMAKE_GENERATOR_INSTANCE is\n"
    "  ${CMAKE_GENERATOR_INSTANCE}\n"
    "which is not an existing directory.")
endif()