Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/acinclude.m4
diff options
context:
space:
mode:
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m416
1 files changed, 16 insertions, 0 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 6693da44..7309d731 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -125,3 +125,19 @@ extern int getmntinfo (struct statfs **, int);
[Defined as the filesystem stats type ('statvfs' or 'statfs')])
])
+dnl Checks for PATH_MAX and defines it if not present
+AC_DEFUN([PATH_MAX_DEFINED],
+ [AC_CACHE_CHECK([PATH_MAX defined], path_max_cv_defined,
+ [AC_EGREP_CPP(yes, [[
+#include <limits.h>
+#if defined(PATH_MAX)
+yes
+#endif
+]],
+ [path_max_cv_defined=yes],
+ [path_max_cv_defined=no])]
+ )
+ if test $path_max_cv_defined = no; then
+ AC_DEFINE([PATH_MAX], 4096, [Define if PATH_MAX is undefined by limits.h.])
+ fi
+])