summaryrefslogtreecommitdiff
path: root/aclocal.m4
diff options
context:
space:
mode:
authorTodd C. Miller <Todd.Miller@courtesan.com>1995-07-17 04:19:42 +0000
committerTodd C. Miller <Todd.Miller@courtesan.com>1995-07-17 04:19:42 +0000
commit1684eea0e8b5c5fa4a4f89eed4ae74a6e1c4aba3 (patch)
treea3fd4a0f4ebb12cba1d756e19e336136fab29b5b /aclocal.m4
parent044da6642ee648b82b51572856555c10d581b959 (diff)
downloadsudo-1684eea0e8b5c5fa4a4f89eed4ae74a6e1c4aba3.tar.gz
added SUDO_CHECK_SHADOW
Diffstat (limited to 'aclocal.m4')
-rw-r--r--aclocal.m416
1 files changed, 16 insertions, 0 deletions
diff --git a/aclocal.m4 b/aclocal.m4
index 805fb89c1..3afe163c9 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,4 +1,5 @@
dnl Local m4 macors for autoconf (used by sudo)
+snl XXX - should cache values in all cases!!!
dnl
dnl checks for programs
@@ -111,6 +112,20 @@ fi
])dnl
dnl
+dnl check for shadow passwords
+dnl
+AC_DEFUN(SUDO_CHECK_SHADOW, [AC_MSG_CHECKING(for shadow passwords)
+AC_TRY_RUN([#include <pwd.h>
+int main() {
+struct passwd *pwd;
+pwd = getpwuid(getuid());
+return(!(pwd->pw_passwd == (char *) 0 || (pwd->pw_passwd[0] && pwd->pw_passwd [1] == '\0'))); }
+], AC_MSG_RESULT(yes)
+[$1], AC_MSG_RESULT(no)
+[$2])])
+
+dnl
+dnl
dnl check for fullly working void
dnl
AC_DEFUN(SUDO_FULL_VOID, [AC_MSG_CHECKING(for full void implementation)
@@ -118,6 +133,7 @@ AC_TRY_COMPILE(, [void *foo;
foo = (void *)0; foo += 0;], AC_DEFINE(VOID, void)
AC_MSG_RESULT(yes), AC_DEFINE(VOID, char)
AC_MSG_RESULT(no))])
+
dnl
dnl SUDO_CHECK_TYPE(TYPE, DEFAULT)
dnl XXX - should require the check for unistd.h...