summaryrefslogtreecommitdiff
path: root/lib/compiler.h
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@diac24.net>2019-05-12 22:39:59 +0200
committerDavid Lamparter <equinox@diac24.net>2019-06-03 16:44:32 +0200
commit8be3678a2331250b0559d07526e66b73d1794d8c (patch)
treea4af45407a189a6d7ee0a03649ce3f070502e1e6 /lib/compiler.h
parente8c672ea8101c541f66e0959d526ae4f5a2a778d (diff)
lib/printf: rename & private __find_arguments
These are internal to printf(), and symbols starting with __ are reserved for the compiler/libc. Signed-off-by: David Lamparter <equinox@diac24.net>
Diffstat (limited to 'lib/compiler.h')
-rw-r--r--lib/compiler.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/compiler.h b/lib/compiler.h
index c2e57db7f8..7509428220 100644
--- a/lib/compiler.h
+++ b/lib/compiler.h
@@ -50,6 +50,16 @@ extern "C" {
#endif
#endif
+#if !defined(__GNUC__)
+#error module code needs GCC visibility extensions
+#elif __GNUC__ < 4
+#error module code needs GCC visibility extensions
+#else
+# define DSO_PUBLIC __attribute__ ((visibility ("default")))
+# define DSO_SELF __attribute__ ((visibility ("protected")))
+# define DSO_LOCAL __attribute__ ((visibility ("hidden")))
+#endif
+
#ifdef __sun
/* Solaris doesn't do constructor priorities due to linker restrictions */
#undef _CONSTRUCTOR