diff --git a/include/posix/pthread.h b/include/posix/pthread.h index fc75eaa7c4d..b93b82861d3 100644 --- a/include/posix/pthread.h +++ b/include/posix/pthread.h @@ -17,6 +17,10 @@ #include #include +#ifdef __cplusplus +extern "C" { +#endif + enum pthread_state { /* The thread structure is unallocated and available for reuse. */ PTHREAD_TERMINATED = 0, @@ -518,4 +522,8 @@ int pthread_key_delete(pthread_key_t key); int pthread_setspecific(pthread_key_t key, const void *value); void *pthread_getspecific(pthread_key_t key); +#ifdef __cplusplus +} +#endif + #endif /* ZEPHYR_INCLUDE_POSIX_PTHREAD_H_ */