summaryrefslogtreecommitdiffstats
path: root/cmake/project-is-top-level.cmake
blob: 3435fc0e48f8c5507f2e8c493236629c3c40be3e (plain)
1
2
3
4
5
6
# This variable is set by project() in CMake 3.21+
string(
    COMPARE EQUAL
    "${CMAKE_SOURCE_DIR}" "${PROJECT_SOURCE_DIR}"
    PROJECT_IS_TOP_LEVEL
)