--- lttng-ust-2.8.0.orig/include/lttng/ust-dlfcn.h +++ lttng-ust-2.8.0/include/lttng/ust-dlfcn.h @@ -31,6 +31,8 @@ #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 +59,9 @@ extern void *dlsym(void *__restrict __handle, __const char *__restrict __name) __nonnull ((2)); extern char *dlerror(void); + +#else +#include +#endif /* __GLIBC__ */ #endif /* _LTTNG_UST_DLFCN_H */