Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tools/compat Add support for missing NAME_MAX when building ...



details:   https://anonhg.NetBSD.org/src/rev/d05f5e62ced4
branches:  trunk
changeset: 377360:d05f5e62ced4
user:      palle <palle%NetBSD.org@localhost>
date:      Sat Jul 08 19:10:00 2023 +0000

description:
Add support for missing NAME_MAX when building on Solaris hosts

diffstat:

 tools/compat/compat_defs.h |  13 ++++++++++++-
 1 files changed, 12 insertions(+), 1 deletions(-)

diffs (27 lines):

diff -r 4edab6ec83ed -r d05f5e62ced4 tools/compat/compat_defs.h
--- a/tools/compat/compat_defs.h        Sat Jul 08 17:43:13 2023 +0000
+++ b/tools/compat/compat_defs.h        Sat Jul 08 19:10:00 2023 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: compat_defs.h,v 1.120 2021/05/30 10:39:41 cjep Exp $   */
+/*     $NetBSD: compat_defs.h,v 1.121 2023/07/08 19:10:00 palle Exp $  */
 
 #ifndef        __NETBSD_COMPAT_DEFS_H__
 #define        __NETBSD_COMPAT_DEFS_H__
@@ -31,6 +31,17 @@
 #endif /* __linux__ && HAVE_FEATURES_H */
 
 /*
+ * Solaris:
+ * No NAME_MAX define is available (as documented in the Solaris
+ * limits.h file), so use the XOPEN defined constant.
+ */
+
+#if defined(__sun__)
+#define NAME_MAX _XOPEN_NAME_MAX
+#endif
+
+
+/*
  * Type substitutes.
  * These are controlled via HAVE_TYPE protections and some of them are needed
  * in other header files (in the build tree not in the host). This is because



Home | Main Index | Thread Index | Old Index