Added extern C {} wrapper consistent with other headers in include/sys

This commit is contained in:
Duane Skelton 2022-08-15 13:49:05 -07:00 committed by Xiang Xiao
parent beb9144141
commit df4b8adacf
1 changed files with 18 additions and 0 deletions

View File

@ -72,10 +72,28 @@ struct utsname
char machine[SYS_NAMELEN]; /* Machine hardware */
};
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
#undef EXTERN
#if defined(__cplusplus)
#define EXTERN extern "C"
extern "C"
{
#else
#define EXTERN extern
#endif
/****************************************************************************
* Public Function Prototypes
****************************************************************************/
int uname(FAR struct utsname *name);
#undef EXTERN
#if defined(__cplusplus)
}
#endif
#endif /* __INCLUDE_SYS_UTSNAME_H */