Add extern "C" in libc-builtin-sysroot pthread.h (#933)
Add extern "C" in libc-builtin-sysroot pthread.h to fix mulit-thread wasm app compiling error with C++ compiler
This commit is contained in:
@ -6,6 +6,10 @@
|
|||||||
#ifndef _WAMR_LIB_PTHREAD_H
|
#ifndef _WAMR_LIB_PTHREAD_H
|
||||||
#define _WAMR_LIB_PTHREAD_H
|
#define _WAMR_LIB_PTHREAD_H
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
/* Data type define of pthread, mutex, cond and key */
|
/* Data type define of pthread, mutex, cond and key */
|
||||||
@ -58,4 +62,8 @@ void *pthread_getspecific(pthread_key_t key);
|
|||||||
|
|
||||||
int pthread_key_delete(pthread_key_t key);
|
int pthread_key_delete(pthread_key_t key);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif /* end of _WAMR_LIB_PTHREAD_H */
|
#endif /* end of _WAMR_LIB_PTHREAD_H */
|
||||||
|
|||||||
Reference in New Issue
Block a user