--- src/auth/basic/PAM/basic_pam_auth.cc.orig	2018-07-02 13:26:07.000000000 +1000
+++ src/auth/basic/PAM/basic_pam_auth.cc	2018-07-22 14:11:40.000000000 +1000
@@ -84,6 +84,11 @@
 #endif
 #if HAVE_SECURITY_PAM_APPL_H
 #include <security/pam_appl.h>
+#elif defined(__APPLE__)
+#include <AvailabilityMacros.h>
+#if defined(MAC_OS_X_VERSION_MIN_REQUIRED) && MAC_OS_X_VERSION_MIN_REQUIRED < 1060
+#include <pam/pam_appl.h>
+#endif
 #endif
 
 /* The default PAM service name */