Skip to content

Commit 670c2c7

Browse files
rcsanchez97kevinAlbs
authored andcommitted
CDRIVER-3756 eliminate CMake function redefinition
1 parent cffdd04 commit 670c2c7

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

CMakeLists.txt

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,6 @@ cmake_minimum_required (VERSION 3.1)
33
# Used in MaintainerFlags.cmake to silence errors while testing configs.
44
set (MESSAGES_ENABLED 1)
55

6-
function (message)
7-
list (GET ARGV 0 MessageType)
8-
if (MESSAGES_ENABLED)
9-
list (REMOVE_AT ARGV 0)
10-
_message (${MessageType} "${ARGV}")
11-
endif ()
12-
endfunction ()
13-
146
set (ENABLE_SSL AUTO CACHE STRING
157
"Enable TLS connections and SCRAM-SHA-1 authentication. Options are
168
\"DARWIN\" to use Apple's Secure Transport, \"WINDOWS\" to use Windows

build/cmake/MaintainerFlags.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ if (ENABLE_MAINTAINER_FLAGS AND NOT MSVC AND NOT MONGOC_MAINTAINER_FLAGS_SET)
1212

1313
foreach (MAINTAINER_FLAG ${MAINTAINER_FLAGS})
1414
# Avoid useless "Performing Test FLAG_OK" message.
15-
set (MESSAGES_ENABLED 0)
15+
set (CMAKE_REQUIRED_QUIET 1)
1616
check_c_compiler_flag ("${MAINTAINER_FLAG}" FLAG_OK)
17-
set (MESSAGES_ENABLED 1)
17+
set (CMAKE_REQUIRED_QUIET 0)
1818
if (FLAG_OK)
1919
message (STATUS "C compiler accepts ${MAINTAINER_FLAG}")
2020
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${MAINTAINER_FLAG}")

0 commit comments

Comments
 (0)