5 dnl Check whether struct dirent has a member named d_type.
8 AC_DEFUN(jm_STRUCT_DIRENT_D_TYPE,
9 [AC_REQUIRE([AC_HEADER_DIRENT])dnl
10 AC_CACHE_CHECK([for d_type member in directory struct],
11 jm_cv_struct_dirent_d_type,
14 #include <sys/types.h>
17 #else /* not HAVE_DIRENT_H */
18 # define dirent direct
19 # ifdef HAVE_SYS_NDIR_H
20 # include <sys/ndir.h>
21 # endif /* HAVE_SYS_NDIR_H */
22 # ifdef HAVE_SYS_DIR_H
24 # endif /* HAVE_SYS_DIR_H */
27 # endif /* HAVE_NDIR_H */
28 #endif /* HAVE_DIRENT_H */
30 [struct dirent dp; dp.d_type = 0;],
32 jm_cv_struct_dirent_d_type=yes,
33 jm_cv_struct_dirent_d_type=no)
36 if test $jm_cv_struct_dirent_d_type = yes; then
37 AC_DEFINE(D_TYPE_IN_DIRENT, 1,
38 [Define if there is a member named d_type in the struct describing