cmake: Check program existence with CMake standards

This commit is contained in:
lat9nq 2024-01-17 15:47:37 -05:00
parent 404d390045
commit b5dc9ac015
2 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@ set(TZ_ZONEINFO_DIR "${TZ_DIR}/usr/share/zoneinfo" CACHE PATH "Time zone info da
set(TZIF_LIST_FILE "${CMAKE_CURRENT_BINARY_DIR}/tzif_list.txt" CACHE PATH "List of zone info files")
find_program(GNU_MAKE make)
if ("${GNU_MAKE}" STREQUAL "GNU_MAKE-NOTFOUND")
if (NOT GNU_MAKE)
message(FATAL_ERROR "GNU make not found")
endif()

View File

@ -1,10 +1,10 @@
find_program(GIT_PROGRAM git)
if ("${GIT_PROGRAM}" STREQUAL "GIT_PROGRAM-NOTFOUND")
if (NOT GIT_PROGRAM)
message(FATAL_ERROR "git program not found")
endif()
find_program(GNU_DATE date)
if ("${GNU_DATE}" STREQUAL "GNU_DATE-NOTFOUND")
if (NOT GNU_DATE)
message(FATAL_ERROR "date program not found")
endif()