mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
11 lines
286 B
CMake
11 lines
286 B
CMake
get_property(role GLOBAL PROPERTY CMAKE_ROLE)
|
|
|
|
file(WRITE "${CMAKE_BINARY_DIR}/test.cmake" "# a")
|
|
include("${CMAKE_BINARY_DIR}/test.cmake")
|
|
|
|
if(NOT role STREQUAL "PROJECT")
|
|
message(SEND_ERROR "CMAKE_ROLE property is \"${role}\", should be \"PROJECT\"")
|
|
endif()
|
|
|
|
add_subdirectory(sub)
|