Only disable deprecation warnings on Apple for OpenSSL
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5a87181..6305be8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -340,9 +340,11 @@ ELSE ()
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-function")
ENDIF()
- CHECK_C_COMPILER_FLAG(-Wno-deprecated-declarations DEPRECATED_DECLARATIONS_WARNING)
- IF(DEPRECATED_DECLARATIONS_WARNING)
- SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-deprecated-declarations")
+ IF (APPLE) # Apple deprecated OpenSSL
+ CHECK_C_COMPILER_FLAG(-Wno-deprecated-declarations DEPRECATED_DECLARATIONS_WARNING)
+ IF(DEPRECATED_DECLARATIONS_WARNING)
+ SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-deprecated-declarations")
+ ENDIF()
ENDIF()
IF (PROFILE)