Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-fs/samba/, net-fs/samba/files/
Date: Fri, 24 Jun 2022 05:26:28
Message-Id: 1656048369.9923d7331d1189316726fcab47ba89a2623f82ab.sam@gentoo
1 commit: 9923d7331d1189316726fcab47ba89a2623f82ab
2 Author: brahmajit das <brahmajit.xyz <AT> gmail <DOT> com>
3 AuthorDate: Tue Jun 21 05:48:08 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Fri Jun 24 05:26:09 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9923d733
7
8 net-fs/samba: Apply the netdb defines patch
9
10 NETDB_INTERNAL and NETDB_INTERNAL are not defined in musl as a result
11 the build is failing.
12
13 Acked-by: David Seifert <soap <AT> gentoo.org>
14 Closes: https://bugs.gentoo.org/835017
15 Closes: https://bugs.gentoo.org/832629
16 Signed-off-by: brahmajit das <brahmajit.xyz <AT> gmail.com>
17 Closes: https://github.com/gentoo/gentoo/pull/26016
18 Signed-off-by: Sam James <sam <AT> gentoo.org>
19
20 net-fs/samba/files/samba-4.16.1-netdb-defines.patch | 21 +++++++++++++++++++++
21 net-fs/samba/samba-4.16.1.ebuild | 1 +
22 2 files changed, 22 insertions(+)
23
24 diff --git a/net-fs/samba/files/samba-4.16.1-netdb-defines.patch b/net-fs/samba/files/samba-4.16.1-netdb-defines.patch
25 new file mode 100644
26 index 000000000000..40aeaa22bfae
27 --- /dev/null
28 +++ b/net-fs/samba/files/samba-4.16.1-netdb-defines.patch
29 @@ -0,0 +1,21 @@
30 +# Define NETDB_INTERNAL and NETDB_SUCCESS if they are not defined
31 +#
32 +# Gentoo bug 832629 and 835017
33 +
34 +--- a/nsswitch/wins.c
35 ++++ b/nsswitch/wins.c
36 +@@ -40,6 +40,14 @@ static pthread_mutex_t wins_nss_mutex = PTHREAD_MUTEX_INITIALIZER;
37 + #define INADDRSZ 4
38 + #endif
39 +
40 ++#ifndef NETDB_INTERNAL
41 ++#define NETDB_INTERNAL -1
42 ++#endif
43 ++
44 ++#ifndef NETDB_SUCCESS
45 ++#define NETDB_SUCCESS 0
46 ++#endif
47 ++
48 + _PUBLIC_ON_LINUX_
49 + NSS_STATUS _nss_wins_gethostbyname_r(const char *hostname,
50 + struct hostent *he,
51
52 diff --git a/net-fs/samba/samba-4.16.1.ebuild b/net-fs/samba/samba-4.16.1.ebuild
53 index a7d3fa8bb5d3..8b16a80d66cb 100644
54 --- a/net-fs/samba/samba-4.16.1.ebuild
55 +++ b/net-fs/samba/samba-4.16.1.ebuild
56 @@ -141,6 +141,7 @@ BDEPEND="${PYTHON_DEPS}
57
58 PATCHES=(
59 "${FILESDIR}/${PN}-4.4.0-pam.patch"
60 + "${FILESDIR}/${PN}-4.16.1-netdb-defines.patch"
61 )
62
63 #CONFDIR="${FILESDIR}/$(get_version_component_range 1-2)"