[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

visibility support

From: Alexei Podtelezhnikov
Subject: visibility support
Date: Fri, 9 Feb 2018 11:39:56 -0500

>> Which LT_INIT option would enable the hidden symbol visibility support?
> Libtool is all about supporting a core set of features in a portable way.

It is not about my use case, which I solved, it is about making
-fvisibility=hidden into a core Libtool feature. I will summarize and
never bother you again.

1) Compile-time -fvisibility=hidden enables additional optimizations
not available with link-time -export-symbols. Both are recommended
together. See

2) This is about portable ELF format. Therefore LT_INIT(elf-hidden)
would be as portable as LT_INIT(win32-dll) if not more. The source
code visibility attributes align with dllexport. The request as about
an option, not the default mode.

3) The broad compiler consensus is there.Why would libtool stay aside
when the debate is over. It is not much different from -fPIC

- GCC does it
- clang does it
- Intel C++ does it
- IBM XL C/C++ does both -fvisibility=hidden and -qvisibility=hidden
- Solaris Studio does -xldscope=hidden and rumored to support
-fvisibility-hidden too
- HP C compiler does -B symbolic

reply via email to

[Prev in Thread] Current Thread [Next in Thread]