diff options
author | Patrick Steinhardt <ps@pks.im> | 2019-08-02 14:00:21 +0200 |
---|---|---|
committer | Patrick Steinhardt <ps@pks.im> | 2019-09-13 10:03:38 +0200 |
commit | 212b6f6559614a4e0deb84a21769d63b92d437a0 (patch) | |
tree | 1ce92ad606421b97a18dcbb565517c3f9e5f0311 /cmake/Modules | |
parent | e77fdf87166e382e8adb7c6f69e9c5e283ed533f (diff) | |
download | libgit2-212b6f6559614a4e0deb84a21769d63b92d437a0.tar.gz |
cmake: fix various misuses of MESSAGE()
The MESSAGE() function expects as first argument the message type, e.g.
STATUS or FATAL_ERROR. In some places, we were misusing this to either
not provide any type, which would then erroneously print the message to
standard error, or to use FATAL instead of FATAL_ERROR.
Fix all of these instances. Also, remove some MESSAGE invocations that
are obvious leftovers from debugging the build system.
Diffstat (limited to 'cmake/Modules')
-rw-r--r-- | cmake/Modules/FindCoreFoundation.cmake | 4 | ||||
-rw-r--r-- | cmake/Modules/FindSecurity.cmake | 4 | ||||
-rw-r--r-- | cmake/Modules/SelectHTTPSBackend.cmake | 4 | ||||
-rw-r--r-- | cmake/Modules/SelectHashes.cmake | 2 |
4 files changed, 7 insertions, 7 deletions
diff --git a/cmake/Modules/FindCoreFoundation.cmake b/cmake/Modules/FindCoreFoundation.cmake index e86ccbf03..191aa595c 100644 --- a/cmake/Modules/FindCoreFoundation.cmake +++ b/cmake/Modules/FindCoreFoundation.cmake @@ -10,14 +10,14 @@ FIND_PATH(COREFOUNDATION_INCLUDE_DIR NAMES CoreFoundation.h) FIND_LIBRARY(COREFOUNDATION_LIBRARIES NAMES CoreFoundation) IF (COREFOUNDATION_INCLUDE_DIR AND COREFOUNDATION_LIBRARIES) IF (NOT CoreFoundation_FIND_QUIETLY) - MESSAGE("-- Found CoreFoundation ${COREFOUNDATION_LIBRARIES}") + MESSAGE(STATUS "Found CoreFoundation ${COREFOUNDATION_LIBRARIES}") ENDIF() SET(COREFOUNDATION_FOUND TRUE) SET(COREFOUNDATION_LDFLAGS "-framework CoreFoundation") ENDIF () IF (CoreFoundation_FIND_REQUIRED AND NOT COREFOUNDATION_FOUND) - MESSAGE(FATAL "-- CoreFoundation not found") + MESSAGE(FATAL_ERROR "CoreFoundation not found") ENDIF() MARK_AS_ADVANCED( diff --git a/cmake/Modules/FindSecurity.cmake b/cmake/Modules/FindSecurity.cmake index 487f7e500..a538c02c1 100644 --- a/cmake/Modules/FindSecurity.cmake +++ b/cmake/Modules/FindSecurity.cmake @@ -11,7 +11,7 @@ FIND_PATH(SECURITY_INCLUDE_DIR NAMES Security/Security.h) FIND_LIBRARY(SECURITY_LIBRARIES NAMES Security) IF (SECURITY_INCLUDE_DIR AND SECURITY_LIBRARIES) IF (NOT Security_FIND_QUIETLY) - MESSAGE("-- Found Security ${SECURITY_LIBRARIES}") + MESSAGE(STATUS "Found Security ${SECURITY_LIBRARIES}") ENDIF() SET(SECURITY_FOUND TRUE) SET(SECURITY_LDFLAGS "-framework Security") @@ -19,7 +19,7 @@ IF (SECURITY_INCLUDE_DIR AND SECURITY_LIBRARIES) ENDIF () IF (Security_FIND_REQUIRED AND NOT SECURITY_FOUND) - MESSAGE(FATAL "-- Security not found") + MESSAGE(FATAL_ERROR "Security not found") ENDIF() MARK_AS_ADVANCED( diff --git a/cmake/Modules/SelectHTTPSBackend.cmake b/cmake/Modules/SelectHTTPSBackend.cmake index 58343ee69..81f3f8b58 100644 --- a/cmake/Modules/SelectHTTPSBackend.cmake +++ b/cmake/Modules/SelectHTTPSBackend.cmake @@ -14,7 +14,7 @@ IF (USE_HTTPS STREQUAL ON) IF (SECURITY_HAS_SSLCREATECONTEXT) SET(HTTPS_BACKEND "SecureTransport") ELSE() - MESSAGE("-- Security framework is too old, falling back to OpenSSL") + MESSAGE(STATUS "Security framework is too old, falling back to OpenSSL") SET(HTTPS_BACKEND "OpenSSL") ENDIF() ELSEIF (WINHTTP) @@ -67,7 +67,7 @@ IF(HTTPS_BACKEND) ENDIF() IF(NOT CERT_LOCATION) - MESSAGE("Auto-detecting default certificates location") + MESSAGE(STATUS "Auto-detecting default certificates location") IF(CMAKE_SYSTEM_NAME MATCHES Darwin) # Check for an Homebrew installation SET(OPENSSL_CMD "/usr/local/opt/openssl/bin/openssl") diff --git a/cmake/Modules/SelectHashes.cmake b/cmake/Modules/SelectHashes.cmake index 5667a9ed1..ce28ac23c 100644 --- a/cmake/Modules/SelectHashes.cmake +++ b/cmake/Modules/SelectHashes.cmake @@ -5,7 +5,7 @@ IF(USE_SHA1 STREQUAL ON OR USE_SHA1 STREQUAL "CollisionDetection") SET(SHA1_BACKEND "CollisionDetection") ELSEIF(USE_SHA1 STREQUAL "HTTPS") - message("Checking HTTPS backend… ${HTTPS_BACKEND}") + message(STATUS "Checking HTTPS backend… ${HTTPS_BACKEND}") IF(HTTPS_BACKEND STREQUAL "SecureTransport") SET(SHA1_BACKEND "CommonCrypto") ELSEIF(HTTPS_BACKEND STREQUAL "WinHTTP") |