Move dlfcn.h availability check to platform_common.h (#1134)
This commit is contained in:
@ -65,6 +65,14 @@ BH_VPRINTF(const char *format, va_list ap);
|
||||
#define NULL (void *)0
|
||||
#endif
|
||||
|
||||
#if !defined(BH_HAS_DLFCN)
|
||||
#if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE)
|
||||
#define BH_HAS_DLFCN 1
|
||||
#else
|
||||
#define BH_HAS_DLFCN 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef __cplusplus
|
||||
|
||||
#ifndef true
|
||||
|
||||
@ -41,6 +41,12 @@ typedef pthread_t korp_thread;
|
||||
#define os_printf printf
|
||||
#define os_vprintf vprintf
|
||||
|
||||
#if defined(CONFIG_LIBC_DLFCN)
|
||||
#define BH_HAS_DLFCN 1
|
||||
#else
|
||||
#define BH_HAS_DLFCN 0
|
||||
#endif
|
||||
|
||||
/* On NuttX, time_t is uint32_t */
|
||||
#define BH_TIME_T_MAX 0xffffffff
|
||||
|
||||
|
||||
Reference in New Issue
Block a user