summaryrefslogtreecommitdiff
path: root/pkgtools/libnbcompat
diff options
context:
space:
mode:
authorabs <abs>2009-02-19 00:51:12 +0000
committerabs <abs>2009-02-19 00:51:12 +0000
commit7eb2375d0aaf1afbb30ee372eae2dab8bbd53c71 (patch)
tree0f12b66ff1c10d09a42c0d94a4e39a1818bf817b /pkgtools/libnbcompat
parent0e7a277772a6f098b73c96c5ad7e2405f4136e98 (diff)
downloadpkgsrc-7eb2375d0aaf1afbb30ee372eae2dab8bbd53c71.tar.gz
Fix PR 40151 - bootstrap of pkgsrc fails on Ubuntu 8.10
- At least Ubuntu 8.1 sets __attribute__((warn_unused_result)) on fwrite() http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25509 which means (void)fwrite(...) will *always* generate a warning, so set -Wno-error to bypass this in Linux.sys.mk - Ubuntu 8.1 also jumps through hoops to ensure ARG_MAX is *undefined*, so work around this in tnftp and libnbcompat
Diffstat (limited to 'pkgtools/libnbcompat')
-rw-r--r--pkgtools/libnbcompat/files/nbcompat/param.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/pkgtools/libnbcompat/files/nbcompat/param.h b/pkgtools/libnbcompat/files/nbcompat/param.h
index 9b804a0fc16..296fe6e52fb 100644
--- a/pkgtools/libnbcompat/files/nbcompat/param.h
+++ b/pkgtools/libnbcompat/files/nbcompat/param.h
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.2 2008/04/29 05:46:08 martin Exp $ */
+/* $NetBSD: param.h,v 1.3 2009/02/19 00:51:12 abs Exp $ */
/*-
* Copyright (c) 2004 The NetBSD Foundation, Inc.
@@ -47,4 +47,9 @@
# define MAX(a, b) ((a) < (b) ? (b) : (a))
#endif
+/* At least Ubuntu 8.10 jumps through hoops to *undefine* ARG_MAX */
+#if !defined(ARG_MAX)
+# define ARG_MAX sysconf(_SC_ARG_MAX)
+#endif
+
#endif /* !_NBCOMPAT_SYS_PARAM_H_ */