From: Marc G. Fournier Date: Thu, 20 Mar 1997 18:04:32 +0000 (+0000) Subject: Check for and set HAVE_CRYPT_H if exists X-Git-Tag: REL6_1~448 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7d5770eaf29c494e9a7830ae02c92a3bec202ab2;p=postgresql Check for and set HAVE_CRYPT_H if exists include crypt.h in password.c if crypt.h does exist --- diff --git a/src/backend/libpq/password.c b/src/backend/libpq/password.c index 6d93b4094d..c7bcb04024 100644 --- a/src/backend/libpq/password.c +++ b/src/backend/libpq/password.c @@ -4,6 +4,9 @@ #include #include #include +#ifdef HAVE_CRYPT +# include +#endif int verify_password(char *user, char *password, Port *port, diff --git a/src/configure b/src/configure index 3770bea703..046fcfd65e 100755 --- a/src/configure +++ b/src/configure @@ -2304,7 +2304,7 @@ else fi done -for ac_hdr in readline.h history.h dld.h +for ac_hdr in readline.h history.h dld.h crypt.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 @@ -2997,7 +2997,7 @@ else fi done -for ac_func in sigprocmask waitpid setsid +for ac_func in sigprocmask waitpid setsid do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo "configure:3004: checking for $ac_func" >&5 diff --git a/src/configure.in b/src/configure.in index d5d18f07db..7b11138c5e 100644 --- a/src/configure.in +++ b/src/configure.in @@ -127,7 +127,7 @@ dnl Checks for header files. AC_HEADER_STDC AC_HEADER_SYS_WAIT AC_CHECK_HEADERS(limits.h unistd.h termios.h values.h sys/select.h) -AC_CHECK_HEADERS(readline.h history.h dld.h) +AC_CHECK_HEADERS(readline.h history.h dld.h crypt.h) dnl Checks for typedefs, structures, and compiler characteristics. AC_C_CONST @@ -160,7 +160,7 @@ AC_FUNC_MEMCMP AC_TYPE_SIGNAL AC_FUNC_VPRINTF AC_CHECK_FUNCS(isinf tzset getrusage vfork memmove sigsetjmp kill sysconf) -AC_CHECK_FUNCS(sigprocmask waitpid setsid) +AC_CHECK_FUNCS(sigprocmask waitpid setsid ) AC_CHECK_FUNC(inet_aton, AC_DEFINE(HAVE_INET_ATON), INET_ATON='inet_aton.o') AC_CHECK_FUNC(strerror, AC_DEFINE(HAVE_STRERROR), STRERROR='strerror.o') AC_CHECK_FUNC(strdup, AC_DEFINE(HAVE_STRDUP), STRDUP='../../utils/strdup.o') diff --git a/src/include/config.h.in b/src/include/config.h.in index 80d42fdd1a..c268f80286 100644 --- a/src/include/config.h.in +++ b/src/include/config.h.in @@ -14,6 +14,9 @@ * The following is set using configure. */ +/* Set to 1 if you have */ +#undef HAVE_CRYPT_H + /* Set to 1 if you have */ #undef HAVE_TERMIOS_H