Hello,
There are still some other compilers left in the world. The Sun, sorry Oracle, compiler, for example, will parse and ignore both __attribute__(visibility()) in the code and -fvisibility=hidden on the commandline, without failing.Adding gcc-ism's without testing for gcc in configure is a terrible idea. Please don't do it. The entire universe doesn't use gcc's non-standard compiler gunk.
cyrus-imapd/configure does check (with cmulocal/visibility.m4) if -fvisibility=hidden / __attribuite__(visibility()) is supported by the compiler. If it is not supported, -fvisibility=hidden is not passed to the compiler, and EXPORTED/HIDDEN expand to nothing. If there are systems, where this logic does not happen, then there is a bug (in the gnulib's lib-symbol-visibility module).
Със здраве Дилян
<<attachment: dilyan_palauzov.vcf>>