summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2000-05-05 11:39:25 +0000
committerJim Meyering <jim@meyering.net>2000-05-05 11:39:25 +0000
commit5d65fd5e991a62d81439e59708ad545c386f808d (patch)
treea411fc4306411019d9d9a702016e2b1dac7d7ff8
parent6a4a7cfe0052a0e2469166f89edbed212d8733aa (diff)
downloadcoreutils-5d65fd5e991a62d81439e59708ad545c386f808d.tar.xz
su doesn't work on Solaris2.6.
When checking for struct spwd.sp_pwdp, also include <shadow.h>. Reported by Dragos Harabor.
-rw-r--r--m4/lib-check.m411
1 files changed, 9 insertions, 2 deletions
diff --git a/m4/lib-check.m4 b/m4/lib-check.m4
index fe5895a38..4439b779a 100644
--- a/m4/lib-check.m4
+++ b/m4/lib-check.m4
@@ -42,10 +42,17 @@ AC_DEFUN(jm_LIB_CHECK,
# shadow passwords. UnixWare 7 needs -lgen.
AC_SEARCH_LIBS(getspnam, [shadow sec gen])
+ AC_CHECK_HEADERS(shadow.h)
+
# Requirements for su.c.
- AC_CHECK_MEMBERS((struct spwd.sp_pwdp))
+ shadow_includes="\
+$ac_includes_default
+#if HAVE_SHADOW_H
+# include <shadow.h>
+#endif
+"
+ AC_CHECK_MEMBERS((struct spwd.sp_pwdp),,,[$shadow_includes])
AC_CHECK_FUNCS(getspnam)
- AC_CHECK_HEADERS(shadow.h)
# SCO-ODT-3.0 is reported to need -lufc for crypt.
# NetBSD needs -lcrypt for crypt.