diff options
author | Thomas Weber <tweber@debian.org> | 2017-01-29 00:02:02 +0100 |
---|---|---|
committer | Thomas Weber <tweber@debian.org> | 2017-02-02 09:43:13 +0100 |
commit | 52aaec67c792c005ee0da585a5150a9c77deaa83 (patch) | |
tree | 8e4431012e14c3500ab877fc327f909757f581cb /configure.ac | |
parent | 844b16be0b5ef6290d5e4002f1236f5658e0926a (diff) | |
download | lcms2-52aaec67c792c005ee0da585a5150a9c77deaa83.tar.gz |
Add "-fvisibility=hidden" to CFLAGS, if supported by compiler
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index e087cfa..093e55c 100644 --- a/configure.ac +++ b/configure.ac @@ -87,6 +87,11 @@ AC_SUBST(inline) # If supported, defines HAVE_FUNC_ATTRIBUTE_VISIBILITY AX_GCC_FUNC_ATTRIBUTE(visibility) +# Check if the compiler supports "-fvisibility=hidden" and if yes, add it to CFLAGS +# This means that symbols that are not marked explicitly for export (CMSAPI) +# will not be reachable in the shared library. +AX_APPEND_COMPILE_FLAGS(["-fvisibility=hidden"]) + # If words are stored with the most significant byte first (like # Motorola and SPARC CPUs), define `WORDS_BIGENDIAN'. AC_C_BIGENDIAN |