>From 93fa3d1ffa46c521cbd85e318b658bed5a5d8462 Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik Date: Tue, 27 May 2014 23:05:08 +0200 Subject: [PATCH 4/7] PAM: Fix compilation of pam_test_client with openpam linuxpam and openpam use different functions for text based conversation. --- src/sss_client/pam_test_client.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/sss_client/pam_test_client.c b/src/sss_client/pam_test_client.c index c9cbffaf4a74b5c9f831cb3feec5de305a8dc182..29d1fcbf01682668d51bf154736aec673bd46501 100644 --- a/src/sss_client/pam_test_client.c +++ b/src/sss_client/pam_test_client.c @@ -27,12 +27,26 @@ #include #include -#include +#ifdef HAVE_SECURITY_PAM_MISC_H +# include +#elif defined(HAVE_SECURITY_OPENPAM_H) +# include +#endif + +#ifdef HAVE_SECURITY_PAM_MISC_H static struct pam_conv conv = { misc_conv, NULL }; +#elif defined(HAVE_SECURITY_OPENPAM_H) +static struct pam_conv conv = { + openpam_ttyconv, + NULL +}; +#else +# error "Missing text based pam conversation function" +#endif int main(int argc, char *argv[]) { -- 1.9.3