Add support for musl libc to ust-dlfcn.h
authorMichael Jeanson <mjeanson@efficios.com>
Mon, 30 May 2016 20:31:30 +0000 (16:31 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Tue, 31 May 2016 04:35:09 +0000 (06:35 +0200)
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
include/lttng/ust-dlfcn.h

index c92f1bb6f320c99f38f61829340377945e7dfb3a..7471d94f689e328b77185cbbb91dc8823b957b6e 100644 (file)
@@ -31,6 +31,7 @@
 #error "Please include lttng/ust-dlfcn.h before dlfcn.h."
 #endif /* _DLFCN_H */
 
+#ifdef __GLIBC__
 /*
  * glibc declares dlsym() and dlerror() with __attribute__((leaf)) (see
  * THROW annotation). Unfortunately, this is not in sync with reality,
@@ -57,5 +58,8 @@ extern int dlclose(void *__handle) __nonnull ((1));
 extern void *dlsym(void *__restrict __handle,
                __const char *__restrict __name) __nonnull ((2));
 extern char *dlerror(void);
+#else
+#include <dlfcn.h>
+#endif /* __GLIBC__ */
 
 #endif /* _LTTNG_UST_DLFCN_H */
This page took 0.025271 seconds and 4 git commands to generate.