--- rts/build/cmake/TestCXXAcceptsVisibilityFlag.cmake.orig 2008-09-18 23:31:26.000000000 +0400 +++ rts/build/cmake/TestCXXAcceptsVisibilityFlag.cmake 2008-10-10 01:22:32.000000000 +0400 @@ -19,6 +19,15 @@ SET(VISIBILITY_HIDDEN "") ENDIF(HAS_VISIBILITY_HIDDEN AND NOT MINGW) ENDIF(NOT DEFINED VISIBILITY_HIDDEN) + +IF(NOT DEFINED VISIBILITY_DEFAULT) + CHECK_CXX_ACCEPTS_FLAG(-fvisibility=default HAS_VISIBILITY_DEFAULT) + IF(HAS_VISIBILITY_DEFAULT AND NOT MINGW) + SET(VISIBILITY_DEFAULT "-fvisibility=default") + ELSE(HAS_VISIBILITY_DEFAULT AND NOT MINGW) + SET(VISIBILITY_DEFAULT "") + ENDIF(HAS_VISIBILITY_DEFAULT AND NOT MINGW) +ENDIF(NOT DEFINED VISIBILITY_DEFAULT) IF(NOT DEFINED VISIBILITY_INLINES_HIDDEN) CHECK_CXX_ACCEPTS_FLAG(-fvisibility-inlines-hidden HAS_VISIBILITY_INLINES_HIDDEN)