From: Graham Perks Date: Fri, 9 Sep 2011 15:17:54 +0000 (-0500) Subject: Add cmake option for visibility=hidden X-Git-Tag: v1.8beta~45 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=837c9ef288bda94bd56953b9a4d5fffc6c8c10b4;p=taglib Add cmake option for visibility=hidden --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 44980f85..0c0c9097 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,6 +11,11 @@ else() endif() OPTION(ENABLE_STATIC_RUNTIME "Visual Studio, link with runtime statically" OFF) +option(VISIBILITY_HIDDEN "Build with -fvisibility=hidden" OFF) +if(VISIBILITY_HIDDEN) + add_definitions (-fvisibility=hidden) +endif() + option(BUILD_TESTS "Build the test suite" OFF) option(BUILD_EXAMPLES "Build the examples" OFF)