summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/inetutils/inetutils/inetutils-only-check-pam_appl.h-when-pam-enabled.patch
blob: 2343c03cb485eac2d56d33b2857547b10db301e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
From cc66e842e037fba9f06761f942abe5c4856492b8 Mon Sep 17 00:00:00 2001
From: Kai Kang <kai.kang@windriver.com>
Date: Wed, 6 Mar 2019 09:36:11 -0500
Subject: [PATCH] inetutils: Import version 1.9.4

Only check security/pam_appl.h which is provided by package libpam when pam is
enabled.

Upstream-Status: Pending

Signed-off-by: Kai Kang <kai.kang@windriver.com>

---
 configure.ac | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 5e16c3a..18510a8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -182,6 +182,19 @@ AC_SUBST(LIBUTIL)
 
 # See if we have libpam.a.  Investigate PAM versus Linux-PAM.
 if test "$with_pam" = yes ; then
+  AC_CHECK_HEADERS([security/pam_appl.h], [], [], [
+#include <sys/types.h>
+#ifdef HAVE_NETINET_IN_SYSTM_H
+# include <netinet/in_systm.h>
+#endif
+#include <netinet/in.h>
+#ifdef HAVE_NETINET_IP_H
+# include <netinet/ip.h>
+#endif
+#ifdef HAVE_SYS_PARAM_H
+# include <sys/param.h>
+#endif
+])
   AC_CHECK_LIB(dl, dlopen, LIBDL=-ldl)
   AC_CHECK_LIB(pam, pam_authenticate, LIBPAM=-lpam)
   if test "$ac_cv_lib_pam_pam_authenticate" = yes ; then
@@ -617,7 +630,7 @@ AC_HEADER_DIRENT
 AC_CHECK_HEADERS([arpa/nameser.h arpa/tftp.h fcntl.h features.h \
 		  glob.h memory.h netinet/ether.h netinet/in_systm.h \
 		  netinet/ip.h netinet/ip_icmp.h netinet/ip_var.h \
-		  security/pam_appl.h shadow.h \
+		  shadow.h \
 		  stropts.h sys/tty.h \
 		  sys/utsname.h sys/ptyvar.h sys/msgbuf.h sys/filio.h \
 		  sys/ioctl_compat.h sys/cdefs.h sys/stream.h sys/mkdev.h \