git: 4f1b8980a5ab - main - net/netatalk3: Fix build on 14.X

From: Joe Marcus Clarke <marcus_at_FreeBSD.org>
Date: Wed, 22 Nov 2023 16:12:38 UTC
The branch main has been updated by marcus:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4f1b8980a5ab4c0b987d38acca809030e9a88adc

commit 4f1b8980a5ab4c0b987d38acca809030e9a88adc
Author:     Joe Marcus Clarke <marcus@FreeBSD.org>
AuthorDate: 2023-11-22 16:10:44 +0000
Commit:     Joe Marcus Clarke <marcus@FreeBSD.org>
CommitDate: 2023-11-22 16:10:44 +0000

    net/netatalk3: Fix build on 14.X
    
    PR:             275261
    With a little help from:        girgen
---
 net/netatalk3/files/patch-etc_uams_uams__dhx2__pam.c | 11 +++++++++++
 net/netatalk3/files/patch-etc_uams_uams__dhx__pam.c  | 19 +++++++++++++++++++
 net/netatalk3/files/patch-etc_uams_uams__pam.c       | 11 +++++++++++
 3 files changed, 41 insertions(+)

diff --git a/net/netatalk3/files/patch-etc_uams_uams__dhx2__pam.c b/net/netatalk3/files/patch-etc_uams_uams__dhx2__pam.c
new file mode 100644
index 000000000000..51c31679b6c8
--- /dev/null
+++ b/net/netatalk3/files/patch-etc_uams_uams__dhx2__pam.c
@@ -0,0 +1,11 @@
+--- etc/uams/uams_dhx2_pam.c.orig	2023-11-22 15:19:12 UTC
++++ etc/uams/uams_dhx2_pam.c
+@@ -136,7 +136,7 @@ error:
+  * echo off means password.
+  */
+ static int PAM_conv (int num_msg,
+-#ifdef LINUX
++#if defined(LINUX) || (defined(FREEBSD) && __FreeBSD_version >= 1400000)
+                      const struct pam_message **msg,
+ #else
+                      struct pam_message **msg,
diff --git a/net/netatalk3/files/patch-etc_uams_uams__dhx__pam.c b/net/netatalk3/files/patch-etc_uams_uams__dhx__pam.c
new file mode 100644
index 000000000000..ec176f5a80d0
--- /dev/null
+++ b/net/netatalk3/files/patch-etc_uams_uams__dhx__pam.c
@@ -0,0 +1,19 @@
+--- etc/uams/uams_dhx_pam.c.orig	2023-11-22 15:18:15 UTC
++++ etc/uams/uams_dhx_pam.c
+@@ -8,6 +8,7 @@
+ #ifdef HAVE_CONFIG_H
+ #include "config.h"
+ #endif /* HAVE_CONFIG_H */
++#include <sys/param.h>
+ 
+ #if defined(USE_PAM) && defined(UAM_DHX)
+ #include <stdio.h>
+@@ -80,7 +80,7 @@ static char *PAM_password;
+  * echo off means password.
+  */
+ static int PAM_conv (int num_msg,
+-#ifdef LINUX
++#if defined(LINUX) || (defined(__FreeBSD_version) && __FreeBSD_version >= 1400000)
+                      const struct pam_message **msg,
+ #else
+                      struct pam_message **msg,
diff --git a/net/netatalk3/files/patch-etc_uams_uams__pam.c b/net/netatalk3/files/patch-etc_uams_uams__pam.c
new file mode 100644
index 000000000000..8bec8c72a221
--- /dev/null
+++ b/net/netatalk3/files/patch-etc_uams_uams__pam.c
@@ -0,0 +1,11 @@
+--- etc/uams/uams_pam.c.orig	2023-11-22 15:00:28 UTC
++++ etc/uams/uams_pam.c
+@@ -53,7 +53,7 @@ extern UAM_MODULE_EXPORT void append(struct papfile *,
+  * echo off means password.
+  */
+ static int PAM_conv (int num_msg,
+-#ifdef LINUX
++#if defined(LINUX) || (defined(FREEBSD) && __FreeBSD_version >= 1400000)
+                      const struct pam_message **msg,
+ #else
+                      struct pam_message **msg,