update to make sure the source directory and build directory are different

This commit is contained in:
Khobaib 2024-09-24 09:38:23 +06:00 committed by GitHub
parent 6dae7eb4a5
commit 4cc8240c5a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,6 +1,13 @@
# Note: CMake support is community-based. The maintainers do not use CMake
# internally.
if(" ${CMAKE_SOURCE_DIR}" STREQUAL " ${CMAKE_BINARY_DIR}")
message(FATAL_ERROR "
FATAL: In-source builds are not allowed.
You should create a separate directory for build files.
")
endif()
cmake_minimum_required(VERSION 3.13)
project(googletest-distribution)