1. prctl() check is not required for host-compile on any OS due to prctl is not used in rpcgen which is only one is compiled during host-compile phase. prctl() check is disabled via HOST_CONFIGURE_VARS in OpenWrt makefile 2. __DARWIN_ONLY_64_BIT_INO_T is true on macos arm64 so struct stat64 and stat64() are not available. This patch defines stat64 as stat if __DARWIN_ONLY_64_BIT_INO_T is true Signed-off-by: Sergey V. Lobanov <sergey@lobanov.in>
17 lines
391 B
Diff
17 lines
391 B
Diff
fix stat64 issue for modern macos versions (including macos arm64)
|
|
|
|
--- a/tools/rpcgen/rpc_main.c
|
|
+++ b/tools/rpcgen/rpc_main.c
|
|
@@ -62,6 +62,12 @@
|
|
#define EXTEND 1 /* alias for TRUE */
|
|
#define DONT_EXTEND 0 /* alias for FALSE */
|
|
|
|
+#ifdef __APPLE__
|
|
+# if __DARWIN_ONLY_64_BIT_INO_T
|
|
+# define stat64 stat
|
|
+# endif
|
|
+#endif
|
|
+
|
|
struct commandline
|
|
{
|
|
int cflag; /* xdr C routines */
|