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/libnfs/files/, net-fs/libnfs/
Date: Sun, 03 Apr 2022 03:41:36
Message-Id: 1648957268.10f85b88567788188f22b3da118cbb38b4aa83f1.sam@gentoo
1 commit: 10f85b88567788188f22b3da118cbb38b4aa83f1
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Sun Apr 3 03:00:51 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Sun Apr 3 03:41:08 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=10f85b88
7
8 net-fs/libnfs: add 5.0.1
9
10 Signed-off-by: Sam James <sam <AT> gentoo.org>
11
12 net-fs/libnfs/Manifest | 1 +
13 .../files/libnfs-5.0.1-pthread-configure.patch | 34 ++++++++++++++++++++++
14 .../{libnfs-9999.ebuild => libnfs-5.0.1.ebuild} | 24 ++++++++++-----
15 net-fs/libnfs/libnfs-9999.ebuild | 20 ++++++++-----
16 4 files changed, 63 insertions(+), 16 deletions(-)
17
18 diff --git a/net-fs/libnfs/Manifest b/net-fs/libnfs/Manifest
19 index 9081fa425b0d..dfece8a6f904 100644
20 --- a/net-fs/libnfs/Manifest
21 +++ b/net-fs/libnfs/Manifest
22 @@ -1 +1,2 @@
23 DIST libnfs-4.0.0.tar.gz 251662 BLAKE2B b6c33c42eb1715b8a996a432b0cc28af1a98cca3389a779378df0931e4d37418937e3ea4938efb4d075b39aac33facca86df3a02bd62d2c7b262859e8d04ecc1 SHA512 3d93d83d1909f24de304c0d47fa6240da7ecf43ce2488a242a58ddabe51d774caf813f5a90ae720a8edd251a765b30e88c0e5b6a13ecb254dfecdc98e30737fa
24 +DIST libnfs-5.0.1.tar.gz 279550 BLAKE2B d27e97f3dce1385cabd8076b673d2bbfe339ff5a34295ca13bfea2f9c2048f4c6dd07a0b54b7cc7e44aecda58dd21520732dc6ee82260f0694a01fec59875a6a SHA512 71f2dcfa8945c1cb6402f5fca10b1f7a4720f7589807d6130eb55361f05ef4684f9cc9a177ece4e13d3847ac6606924115fac7b27749cecc2f5aca6fa9c63ebf
25
26 diff --git a/net-fs/libnfs/files/libnfs-5.0.1-pthread-configure.patch b/net-fs/libnfs/files/libnfs-5.0.1-pthread-configure.patch
27 new file mode 100644
28 index 000000000000..91c3781389b4
29 --- /dev/null
30 +++ b/net-fs/libnfs/files/libnfs-5.0.1-pthread-configure.patch
31 @@ -0,0 +1,34 @@
32 +https://github.com/sahlberg/libnfs/pull/380
33 +
34 +From af37ac6d766755185dc023b940cfe78a176170a0 Mon Sep 17 00:00:00 2001
35 +From: Sam James <sam@g.o>
36 +Date: Sun, 3 Apr 2022 04:22:04 +0100
37 +Subject: [PATCH] autotools: fix syntax error in configure when pthreads
38 + disabled
39 +
40 +Avoids this warning/syntax error in configure when pthreads aren't
41 +enabled (default):
42 +```
43 +checking for special C compiler options needed for large files... no
44 +checking for _FILE_OFFSET_BITS value needed for large files... no
45 +./configure: 14227: test: =: unexpected operator
46 +checking whether SO_BINDTODEVICE is available... yes
47 +checking whether getpwnam() is available... yes
48 +```
49 +
50 +The LHS of the test will be blank, so use an 'x' to give a dummy
51 +value, like we do elsewhere.
52 +
53 +Signed-off-by: Sam James <sam@g.o>
54 +--- a/configure.ac
55 ++++ b/configure.ac
56 +@@ -88,7 +88,7 @@ if test x"$libnfs_cv_HAVE_PTHREAD" = x"yes"; then
57 + AC_DEFINE(HAVE_MULTITHREADING,1,[Whether we have multithreading support])
58 + fi
59 + fi
60 +-AM_CONDITIONAL([HAVE_PTHREAD], [test $libnfs_cv_HAVE_PTHREAD = yes])
61 ++AM_CONDITIONAL([HAVE_PTHREAD], [test x$libnfs_cv_HAVE_PTHREAD = xyes])
62 +
63 + AC_MSG_CHECKING(whether SO_BINDTODEVICE is available)
64 + AC_TRY_COMPILE([#include <net/if.h>], [
65 +
66
67 diff --git a/net-fs/libnfs/libnfs-9999.ebuild b/net-fs/libnfs/libnfs-5.0.1.ebuild
68 similarity index 75%
69 copy from net-fs/libnfs/libnfs-9999.ebuild
70 copy to net-fs/libnfs/libnfs-5.0.1.ebuild
71 index 2736936d4bfc..697b530e9448 100644
72 --- a/net-fs/libnfs/libnfs-9999.ebuild
73 +++ b/net-fs/libnfs/libnfs-5.0.1.ebuild
74 @@ -1,31 +1,36 @@
75 -# Copyright 1999-2020 Gentoo Authors
76 +# Copyright 1999-2022 Gentoo Authors
77 # Distributed under the terms of the GNU General Public License v2
78
79 -EAPI=6
80 +EAPI=7
81
82 inherit autotools
83 -if [[ ${PV} == "9999" ]] ; then
84 +if [[ ${PV} == 9999 ]] ; then
85 inherit git-r3
86 EGIT_REPO_URI="https://github.com/sahlberg/${PN}.git"
87 else
88 SRC_URI="https://github.com/sahlberg/${PN}/archive/${P}.tar.gz"
89 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~x86"
90 - S="${WORKDIR}/${PN}-${P}"
91 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~x86"
92 + S="${WORKDIR}"/${PN}-${P}
93 fi
94
95 DESCRIPTION="Client library for accessing NFS shares over a network"
96 HOMEPAGE="https://github.com/sahlberg/libnfs"
97
98 LICENSE="LGPL-2.1 GPL-3"
99 -SLOT="0/13" # sub-slot matches SONAME major
100 +SLOT="0/14" # sub-slot matches SONAME major
101 IUSE="examples static-libs utils"
102
103 -RDEPEND=""
104 -DEPEND="${RDEPEND}
105 +# net-libs/rpcsvc-proto for rpcgen called in build system
106 +BDEPEND="net-libs/rpcsvc-proto
107 virtual/pkgconfig"
108
109 +PATCHES=(
110 + "${FILESDIR}"/libnfs-5.0.1-pthread-configure.patch
111 +)
112 +
113 src_prepare() {
114 default
115 +
116 eautoreconf
117 }
118
119 @@ -35,11 +40,13 @@ src_configure() {
120 $(use_enable static-libs static)
121 $(use_enable utils)
122 )
123 +
124 econf "${myeconfargs[@]}"
125 }
126
127 src_install() {
128 default
129 +
130 if use examples; then
131 # --enable-examples configure switch just compiles them
132 # better install sources instead
133 @@ -48,5 +55,6 @@ src_install() {
134 doexe examples/${program}.c
135 done
136 fi
137 +
138 find "${ED}" -name "*.la" -delete || die
139 }
140
141 diff --git a/net-fs/libnfs/libnfs-9999.ebuild b/net-fs/libnfs/libnfs-9999.ebuild
142 index 2736936d4bfc..c586e1123012 100644
143 --- a/net-fs/libnfs/libnfs-9999.ebuild
144 +++ b/net-fs/libnfs/libnfs-9999.ebuild
145 @@ -1,31 +1,32 @@
146 -# Copyright 1999-2020 Gentoo Authors
147 +# Copyright 1999-2022 Gentoo Authors
148 # Distributed under the terms of the GNU General Public License v2
149
150 -EAPI=6
151 +EAPI=7
152
153 inherit autotools
154 -if [[ ${PV} == "9999" ]] ; then
155 +if [[ ${PV} == 9999 ]] ; then
156 inherit git-r3
157 EGIT_REPO_URI="https://github.com/sahlberg/${PN}.git"
158 else
159 SRC_URI="https://github.com/sahlberg/${PN}/archive/${P}.tar.gz"
160 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~x86"
161 - S="${WORKDIR}/${PN}-${P}"
162 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~x86"
163 + S="${WORKDIR}"/${PN}-${P}
164 fi
165
166 DESCRIPTION="Client library for accessing NFS shares over a network"
167 HOMEPAGE="https://github.com/sahlberg/libnfs"
168
169 LICENSE="LGPL-2.1 GPL-3"
170 -SLOT="0/13" # sub-slot matches SONAME major
171 +SLOT="0/14" # sub-slot matches SONAME major
172 IUSE="examples static-libs utils"
173
174 -RDEPEND=""
175 -DEPEND="${RDEPEND}
176 +# net-libs/rpcsvc-proto for rpcgen called in build system
177 +BDEPEND="net-libs/rpcsvc-proto
178 virtual/pkgconfig"
179
180 src_prepare() {
181 default
182 +
183 eautoreconf
184 }
185
186 @@ -35,11 +36,13 @@ src_configure() {
187 $(use_enable static-libs static)
188 $(use_enable utils)
189 )
190 +
191 econf "${myeconfargs[@]}"
192 }
193
194 src_install() {
195 default
196 +
197 if use examples; then
198 # --enable-examples configure switch just compiles them
199 # better install sources instead
200 @@ -48,5 +51,6 @@ src_install() {
201 doexe examples/${program}.c
202 done
203 fi
204 +
205 find "${ED}" -name "*.la" -delete || die
206 }