Explorar o código

Make sure the hidden visibility variables never get set on MINGW.

Stephen Kelly %!s(int64=14) %!d(string=hai) anos
pai
achega
1f3be45048
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      Modules/GenerateExportHeader.cmake

+ 2 - 2
Modules/GenerateExportHeader.cmake

@@ -132,7 +132,7 @@ macro(_test_compiler_hidden_visibility)
     endif()
   endif()
 
-  if (NOT GCC_TOO_OLD)
+  if (NOT GCC_TOO_OLD AND NOT MINGW)
     check_cxx_compiler_flag(-fvisibility=hidden COMPILER_HAS_HIDDEN_VISIBILITY)
     check_cxx_compiler_flag(-fvisibility-inlines-hidden COMPILER_HAS_HIDDEN_INLINE_VISIBILITY)
     option(USE_COMPILER_HIDDEN_VISIBILITY "Use HIDDEN visibility support if available." ON)
@@ -252,7 +252,7 @@ function(add_compiler_export_flags)
 
   _test_compiler_hidden_visibility()
 
-  if(NOT (USE_COMPILER_HIDDEN_VISIBILITY AND COMPILER_HAS_HIDDEN_VISIBILITY) OR MINGW)
+  if(NOT (USE_COMPILER_HIDDEN_VISIBILITY AND COMPILER_HAS_HIDDEN_VISIBILITY))
     message(WARNING "Compiler doesn't have hidden visibility")
     return()
   endif()