From d5d91f68e57470ae83041fdf18627a5c2df9ccca Mon Sep 17 00:00:00 2001 From: SwitchJS Date: Sun, 23 Jun 2019 13:05:51 -0700 Subject: [PATCH] stub --- nx/external/bsd/include/sys/utsname.h | 31 +++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 nx/external/bsd/include/sys/utsname.h diff --git a/nx/external/bsd/include/sys/utsname.h b/nx/external/bsd/include/sys/utsname.h new file mode 100644 index 00000000..b9456597 --- /dev/null +++ b/nx/external/bsd/include/sys/utsname.h @@ -0,0 +1,31 @@ +/* + * Technically compliant implementation based on POSIX specification + */ +#ifndef _SYS_UTSNAME_H_ +#define _SYS_UTSNAME_H_ + +/* + * "The character arrays are of unspecified size" assume 63 + null byte + * + * Members are stored in the order specified in the POSIX description + */ +struct utsname { + char sysname[64]; + char nodename[64]; + char release[64]; + char version[64]; + char machine[64]; +}; + +/* + * `uname` can be defined as a macro or a function, so inline is fair game. + * + * -1 shall be returned on error. + * + * Note: errno should be set, but the spec doesn't give a list of valid codes. + */ +static inline int uname(struct utsname *name) { + return -1; +} + +#endif