summaryrefslogtreecommitdiffstats
path: root/source/configure.in
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-01-10 01:49:09 +0000
committerJeremy Allison <jra@samba.org>2002-01-10 01:49:09 +0000
commitee8c8add7f83d7a794546769c59c85ef8bb5b89a (patch)
tree6266bdfc32bf3de69bb1b682728f9863893b167b /source/configure.in
parentee0a6f8d26a594bb3d0ee266a0229f3046590270 (diff)
downloadsamba-ee8c8add7f83d7a794546769c59c85ef8bb5b89a.tar.gz
samba-ee8c8add7f83d7a794546769c59c85ef8bb5b89a.tar.xz
samba-ee8c8add7f83d7a794546769c59c85ef8bb5b89a.zip
We need to test for major/minor macros.
Jeremy.
Diffstat (limited to 'source/configure.in')
-rw-r--r--source/configure.in24
1 files changed, 24 insertions, 0 deletions
diff --git a/source/configure.in b/source/configure.in
index ed5bc605efc..864999332cf 100644
--- a/source/configure.in
+++ b/source/configure.in
@@ -899,6 +899,30 @@ if test x"$samba_cv_HAVE_STRUCT_DIRENT64" = x"yes"; then
AC_DEFINE(HAVE_STRUCT_DIRENT64)
fi
+AC_CACHE_CHECK([for major macro],samba_cv_HAVE_DEVICE_MAJOR_FN,[
+AC_TRY_RUN([
+#if defined(HAVE_UNISTD_H)
+#include <unistd.h>
+#endif
+#include <sys/types.h>
+main() { dev_t dev; int i = major(dev); return 0; }],
+samba_cv_HAVE_DEVICE_MAJOR_FN=yes,samba_cv_HAVE_DEVICE_MAJOR_FN=no,samba_cv_HAVE_DEVICE_MAJOR_FN=cross)])
+if test x"$samba_cv_HAVE_DEVICE_MAJOR_FN" = x"yes"; then
+ AC_DEFINE(HAVE_DEVICE_MAJOR_FN)
+fi
+
+AC_CACHE_CHECK([for minor macro],samba_cv_HAVE_DEVICE_MINOR_FN,[
+AC_TRY_RUN([
+#if defined(HAVE_UNISTD_H)
+#include <unistd.h>
+#endif
+#include <sys/types.h>
+main() { dev_t dev; int i = minor(dev); return 0; }],
+samba_cv_HAVE_DEVICE_MINOR_FN=yes,samba_cv_HAVE_DEVICE_MINOR_FN=no,samba_cv_HAVE_DEVICE_MINOR_FN=cross)])
+if test x"$samba_cv_HAVE_DEVICE_MINOR_FN" = x"yes"; then
+ AC_DEFINE(HAVE_DEVICE_MINOR_FN)
+fi
+
AC_CACHE_CHECK([for unsigned char],samba_cv_HAVE_UNSIGNED_CHAR,[
AC_TRY_RUN([#include <stdio.h>
main() { char c; c=250; exit((c > 0)?0:1); }],