Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libxml2/files/, dev-libs/libxml2/
Date: Tue, 03 May 2022 00:50:13
Message-Id: 1651538341.8bbbe5e4ec96f6c8b2d2858f9c23fa8a24a797f2.sam@gentoo
1 commit: 8bbbe5e4ec96f6c8b2d2858f9c23fa8a24a797f2
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 3 00:38:04 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Tue May 3 00:39:01 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8bbbe5e4
7
8 dev-libs/libxml2: add 2.9.14
9
10 Bug: https://bugs.gentoo.org/842261
11 Closes: https://bugs.gentoo.org/582130
12 Signed-off-by: Sam James <sam <AT> gentoo.org>
13
14 dev-libs/libxml2/Manifest | 1 +
15 .../files/libxml2-2.9.13-testapi-missing-xml.patch | 9 ----
16 .../files/libxml2-2.9.8-out-of-tree-test.patch | 31 +++++++++++++
17 .../{libxml2-9999.ebuild => libxml2-2.9.14.ebuild} | 51 +++++++++++++---------
18 dev-libs/libxml2/libxml2-9999.ebuild | 51 +++++++++++++---------
19 5 files changed, 92 insertions(+), 51 deletions(-)
20
21 diff --git a/dev-libs/libxml2/Manifest b/dev-libs/libxml2/Manifest
22 index 09beb394762d..ff7171e5e024 100644
23 --- a/dev-libs/libxml2/Manifest
24 +++ b/dev-libs/libxml2/Manifest
25 @@ -1,5 +1,6 @@
26 DIST libxml2-2.9.12-r5-patchset.tar.bz2 7231 BLAKE2B d9d0d56ebccbfe234a8af04cc5343c1a02d84fbd998c2373fd48be59cf92807a9417db650a6bb6ba309e101994c4ae2b28edda7bf635c7728eb8b8047d0d3391 SHA512 b2db0fe4595c1559d9f8dc836ee6eee469191f6c490fc95d25d9fa99a544e80858894cc35b6e4a6624a38d0309800540badc929e86ef29950c1107caa4656a14
27 DIST libxml2-2.9.13.tar.xz 3243336 BLAKE2B 845a8283cf1ff9fd9f7926cfe0042c042a9de5ed184520d8057f7b33312687d5ff28abdf30dd2674795d78dc80326203a907f9e22cd261805309403ecdd585f5 SHA512 fc51980cb9222bd3b5242f73d28b55fa15a80e68e52e1c45274f1eda11500ed385853209edb3b2a1f06b9de0be304c159a9bd898c7d84b0899eacb00723d98b5
28 +DIST libxml2-2.9.14.tar.xz 3129968 BLAKE2B ab584503d5209e4aaf41ae6f44aed5e94c0ae29e28cfba39a9012568aa97515af861b47891b84d2a352a07357626ba50ddb1e344e911fa14ff2ce93c5beff1f1 SHA512 d08e6cafb289c499fdc5b3a12181e032a34f7a249bc66758859f964d3e71e19fd69be79921e1a9d8ab1e692d15b13f5fae95eeb10c3236974d89e218f5107606
29 DIST xmlts20130923.tar.gz 641522 BLAKE2B 63a47bc69278ef510cd0b3779aed729e1b309e30efa0015d28ed051cc03f9dfddb447ab57b07b3393e8f47393d15473b0e199c34cb1f5f746b15ddfaa55670be SHA512 d5c4d26b324ed21f4e0641cd7f8b76dbf9de80df8b519982e44d41c960df29fd03618e02e9693b2d11ad06d19c4a965274c95a048ec3b9653eacb919a7f8b733
30 DIST xsts-2002-01-16.tar.gz 6894439 BLAKE2B 1e9ec63d2c104655e64249e07440a04d862fcbcd4d4e19745d81b34994319b510a531c9d6df1491fae1e90b5d0764f0f1a827251ca8df5d613178b0eab01ef25 SHA512 43300af6d39c1e2221b0ed7318fe14c7464eeb6eb030ed1e22eb29b4ab17f014e2a4c8887c3a46ae5d243e3072da27f00f4e285498ae6f1288177d38d1108288
31 DIST xsts-2004-01-14.tar.gz 2761085 BLAKE2B 41545995fb3a65d053257c376c07d45ffd1041a433bfbdb46d4dd87a5afb60c18c8629a3d988323f9e7a1d709775b5a7e5930276a7121c0725a22705c0976e36 SHA512 32854388d7e720ad67156baf50bf2bae7bd878ca3e35fd7e44e57cad3f434f69d56bbbedd61509f8a1faf01c9eae74a078df8fe130780b182c05c05cb1c39ebe
32
33 diff --git a/dev-libs/libxml2/files/libxml2-2.9.13-testapi-missing-xml.patch b/dev-libs/libxml2/files/libxml2-2.9.13-testapi-missing-xml.patch
34 index adbb3db72a5a..fa8e3d392d18 100644
35 --- a/dev-libs/libxml2/files/libxml2-2.9.13-testapi-missing-xml.patch
36 +++ b/dev-libs/libxml2/files/libxml2-2.9.13-testapi-missing-xml.patch
37 @@ -6,12 +6,6 @@ Subject: [PATCH] testapi: remove leading slash from "/missing.xml"
38 Fixes an error when running tests in a sandbox on Gentoo Linux.
39
40 Bug: https://bugs.gentoo.org/839804
41 ----
42 - testapi.c | 2 +-
43 - 1 file changed, 1 insertion(+), 1 deletion(-)
44 -
45 -diff --git a/testapi.c b/testapi.c
46 -index d4258c43..c7a5b163 100644
47 --- a/testapi.c
48 +++ b/testapi.c
49 @@ -442,7 +442,7 @@ static void des_eaten_name(int no ATTRIBUTE_UNUSED, xmlChar *val ATTRIBUTE_UNUSE
50 @@ -23,6 +17,3 @@ index d4258c43..c7a5b163 100644
51 if (no == 1) return("<foo/>");
52 if (no == 2) return(REMOTE2GOOD);
53 if (no == 3) return(REMOTE1GOOD);
54 ---
55 -2.35.1
56 -
57
58 diff --git a/dev-libs/libxml2/files/libxml2-2.9.8-out-of-tree-test.patch b/dev-libs/libxml2/files/libxml2-2.9.8-out-of-tree-test.patch
59 new file mode 100644
60 index 000000000000..468214d0bd8b
61 --- /dev/null
62 +++ b/dev-libs/libxml2/files/libxml2-2.9.8-out-of-tree-test.patch
63 @@ -0,0 +1,31 @@
64 +https://gitlab.gnome.org/GNOME/libxml2/merge_requests/14
65 +
66 +From 54878c018af979b20ca1bfbf12599973484cae5b Mon Sep 17 00:00:00 2001
67 +From: Mike Frysinger <vapier@g.o>
68 +Date: Thu, 3 Jan 2019 05:44:03 -0500
69 +Subject: [PATCH] fix reader5.py test when building out of tree
70 +
71 +When building out of tree, the relative path this test uses doesn't
72 +work. Resolve the path relative to the test script itself instead.
73 +
74 +Url: https://bugs.gentoo.org/565576
75 +--- a/python/tests/reader5.py
76 ++++ b/python/tests/reader5.py
77 +@@ -4,6 +4,7 @@
78 + # this extract the Dragon bibliography entries from the XML specification
79 + #
80 + import libxml2
81 ++import os
82 + import sys
83 +
84 + # Memory debug specific
85 +@@ -14,7 +15,8 @@ Ravi Sethi, and Jeffrey D. Ullman.
86 + <emph>Compilers: Principles, Techniques, and Tools</emph>.
87 + Reading: Addison-Wesley, 1986, rpt. corr. 1988.</bibl>"""
88 +
89 +-f = open('../../test/valid/REC-xml-19980210.xml', 'rb')
90 ++basedir = os.path.dirname(os.path.realpath(__file__))
91 ++f = open(os.path.join(basedir, '../../test/valid/REC-xml-19980210.xml'), 'rb')
92 + input = libxml2.inputBuffer(f)
93 + reader = input.newTextReader("REC")
94 + res=""
95
96 diff --git a/dev-libs/libxml2/libxml2-9999.ebuild b/dev-libs/libxml2/libxml2-2.9.14.ebuild
97 similarity index 80%
98 copy from dev-libs/libxml2/libxml2-9999.ebuild
99 copy to dev-libs/libxml2/libxml2-2.9.14.ebuild
100 index 3ad0604b6f1e..847a7c331d40 100644
101 --- a/dev-libs/libxml2/libxml2-9999.ebuild
102 +++ b/dev-libs/libxml2/libxml2-2.9.14.ebuild
103 @@ -7,7 +7,7 @@ EAPI=8
104
105 PYTHON_COMPAT=( python3_{8..10} )
106 PYTHON_REQ_USE="xml"
107 -inherit autotools flag-o-matic python-r1 multilib-minimal
108 +inherit flag-o-matic python-r1 multilib-minimal
109
110 XSTS_HOME="http://www.w3.org/XML/2004/xml-schema-test-suite"
111 XSTS_NAME_1="xmlschema2002-01-16"
112 @@ -20,10 +20,10 @@ DESCRIPTION="XML C parser and toolkit"
113 HOMEPAGE="http://www.xmlsoft.org/ https://gitlab.gnome.org/GNOME/libxml2"
114 if [[ ${PV} == 9999 ]] ; then
115 EGIT_REPO_URI="https://gitlab.gnome.org/GNOME/libxml2"
116 - inherit git-r3
117 + inherit autotools git-r3
118 else
119 - inherit gnome.org
120 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
121 + inherit gnome.org libtool
122 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
123 fi
124
125 SRC_URI+="
126 @@ -40,18 +40,17 @@ IUSE="debug examples icu lzma +python readline static-libs test"
127 RESTRICT="!test? ( test )"
128 REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
129
130 -BDEPEND="
131 - dev-util/gtk-doc-am
132 - virtual/pkgconfig
133 -"
134 -RDEPEND="
135 - >=sys-libs/zlib-1.2.8-r1:=[${MULTILIB_USEDEP}]
136 +RDEPEND=">=sys-libs/zlib-1.2.8-r1:=[${MULTILIB_USEDEP}]
137 icu? ( >=dev-libs/icu-51.2-r1:=[${MULTILIB_USEDEP}] )
138 lzma? ( >=app-arch/xz-utils-5.0.5-r1:=[${MULTILIB_USEDEP}] )
139 python? ( ${PYTHON_DEPS} )
140 - readline? ( sys-libs/readline:= )
141 -"
142 + readline? ( sys-libs/readline:= )"
143 DEPEND="${RDEPEND}"
144 +BDEPEND="virtual/pkgconfig"
145 +
146 +if [[ ${PV} == 9999 ]] ; then
147 + BDEPEND+=" dev-util/gtk-doc-am"
148 +fi
149
150 MULTILIB_CHOST_TOOLS=(
151 /usr/bin/xml2-config
152 @@ -59,6 +58,10 @@ MULTILIB_CHOST_TOOLS=(
153
154 DOCS=( NEWS README.md TODO TODO_SCHEMAS python/TODO )
155
156 +PATCHES=(
157 + "${FILESDIR}"/${PN}-2.9.8-out-of-tree-test.patch
158 +)
159 +
160 src_unpack() {
161 if [[ ${PV} == 9999 ]] ; then
162 git-r3_src_unpack
163 @@ -67,7 +70,11 @@ src_unpack() {
164
165 # ${A} isn't used to avoid unpacking of test tarballs into ${WORKDIR},
166 # as they are needed as tarballs in ${S}/xstc instead and not unpacked
167 - unpack ${tarname} ${PN}-${PATCHSET_VERSION}.tar.bz2
168 + unpack ${tarname}
169 +
170 + if [[ -n ${PATCHSET_VERSION} ]] ; then
171 + unpack ${PN}-${PATCHSET_VERSION}.tar.bz2
172 + fi
173 fi
174
175 cd "${S}" || die
176 @@ -84,22 +91,22 @@ src_unpack() {
177 src_prepare() {
178 default
179
180 - # Please do not remove, as else we get references to PORTAGE_TMPDIR
181 - # in /usr/lib/python?.?/site-packages/libxml2mod.la among things.
182 - # We now need to run eautoreconf at the end to prevent maintainer mode.
183 - #elibtoolize
184 - # Needed for https://gitlab.gnome.org/GNOME/libxml2/-/issues/338 too in 2.9.13
185 - eautoreconf
186 + if [[ ${PV} == 9999 ]] ; then
187 + eautoreconf
188 + else
189 + # Please do not remove, as else we get references to PORTAGE_TMPDIR
190 + # in /usr/lib/python?.?/site-packages/libxml2mod.la among things.
191 + elibtoolize
192 + fi
193 }
194
195 multilib_src_configure() {
196 - # Filter seemingly problematic CFLAGS (#26320)
197 + # Filter seemingly problematic CFLAGS (bug #26320)
198 filter-flags -fprefetch-loop-arrays -funroll-loops
199
200 # Notes:
201 # The meaning of the 'debug' USE flag does not apply to the --with-debug
202 # switch (enabling the libxml2 debug module). See bug #100898.
203 -
204 libxml2_configure() {
205 ECONF_SOURCE="${S}" econf \
206 --enable-ipv6 \
207 @@ -160,6 +167,8 @@ multilib_src_install_all() {
208 rm -rf "${ED}"/usr/share/doc/${PF}/python/examples || die
209 fi
210
211 + rm -rf "${ED}"/usr/share/doc/${PN}-python-${PVR} || die
212 +
213 find "${ED}" -name '*.la' -delete || die
214 }
215
216
217 diff --git a/dev-libs/libxml2/libxml2-9999.ebuild b/dev-libs/libxml2/libxml2-9999.ebuild
218 index 3ad0604b6f1e..847a7c331d40 100644
219 --- a/dev-libs/libxml2/libxml2-9999.ebuild
220 +++ b/dev-libs/libxml2/libxml2-9999.ebuild
221 @@ -7,7 +7,7 @@ EAPI=8
222
223 PYTHON_COMPAT=( python3_{8..10} )
224 PYTHON_REQ_USE="xml"
225 -inherit autotools flag-o-matic python-r1 multilib-minimal
226 +inherit flag-o-matic python-r1 multilib-minimal
227
228 XSTS_HOME="http://www.w3.org/XML/2004/xml-schema-test-suite"
229 XSTS_NAME_1="xmlschema2002-01-16"
230 @@ -20,10 +20,10 @@ DESCRIPTION="XML C parser and toolkit"
231 HOMEPAGE="http://www.xmlsoft.org/ https://gitlab.gnome.org/GNOME/libxml2"
232 if [[ ${PV} == 9999 ]] ; then
233 EGIT_REPO_URI="https://gitlab.gnome.org/GNOME/libxml2"
234 - inherit git-r3
235 + inherit autotools git-r3
236 else
237 - inherit gnome.org
238 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
239 + inherit gnome.org libtool
240 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
241 fi
242
243 SRC_URI+="
244 @@ -40,18 +40,17 @@ IUSE="debug examples icu lzma +python readline static-libs test"
245 RESTRICT="!test? ( test )"
246 REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
247
248 -BDEPEND="
249 - dev-util/gtk-doc-am
250 - virtual/pkgconfig
251 -"
252 -RDEPEND="
253 - >=sys-libs/zlib-1.2.8-r1:=[${MULTILIB_USEDEP}]
254 +RDEPEND=">=sys-libs/zlib-1.2.8-r1:=[${MULTILIB_USEDEP}]
255 icu? ( >=dev-libs/icu-51.2-r1:=[${MULTILIB_USEDEP}] )
256 lzma? ( >=app-arch/xz-utils-5.0.5-r1:=[${MULTILIB_USEDEP}] )
257 python? ( ${PYTHON_DEPS} )
258 - readline? ( sys-libs/readline:= )
259 -"
260 + readline? ( sys-libs/readline:= )"
261 DEPEND="${RDEPEND}"
262 +BDEPEND="virtual/pkgconfig"
263 +
264 +if [[ ${PV} == 9999 ]] ; then
265 + BDEPEND+=" dev-util/gtk-doc-am"
266 +fi
267
268 MULTILIB_CHOST_TOOLS=(
269 /usr/bin/xml2-config
270 @@ -59,6 +58,10 @@ MULTILIB_CHOST_TOOLS=(
271
272 DOCS=( NEWS README.md TODO TODO_SCHEMAS python/TODO )
273
274 +PATCHES=(
275 + "${FILESDIR}"/${PN}-2.9.8-out-of-tree-test.patch
276 +)
277 +
278 src_unpack() {
279 if [[ ${PV} == 9999 ]] ; then
280 git-r3_src_unpack
281 @@ -67,7 +70,11 @@ src_unpack() {
282
283 # ${A} isn't used to avoid unpacking of test tarballs into ${WORKDIR},
284 # as they are needed as tarballs in ${S}/xstc instead and not unpacked
285 - unpack ${tarname} ${PN}-${PATCHSET_VERSION}.tar.bz2
286 + unpack ${tarname}
287 +
288 + if [[ -n ${PATCHSET_VERSION} ]] ; then
289 + unpack ${PN}-${PATCHSET_VERSION}.tar.bz2
290 + fi
291 fi
292
293 cd "${S}" || die
294 @@ -84,22 +91,22 @@ src_unpack() {
295 src_prepare() {
296 default
297
298 - # Please do not remove, as else we get references to PORTAGE_TMPDIR
299 - # in /usr/lib/python?.?/site-packages/libxml2mod.la among things.
300 - # We now need to run eautoreconf at the end to prevent maintainer mode.
301 - #elibtoolize
302 - # Needed for https://gitlab.gnome.org/GNOME/libxml2/-/issues/338 too in 2.9.13
303 - eautoreconf
304 + if [[ ${PV} == 9999 ]] ; then
305 + eautoreconf
306 + else
307 + # Please do not remove, as else we get references to PORTAGE_TMPDIR
308 + # in /usr/lib/python?.?/site-packages/libxml2mod.la among things.
309 + elibtoolize
310 + fi
311 }
312
313 multilib_src_configure() {
314 - # Filter seemingly problematic CFLAGS (#26320)
315 + # Filter seemingly problematic CFLAGS (bug #26320)
316 filter-flags -fprefetch-loop-arrays -funroll-loops
317
318 # Notes:
319 # The meaning of the 'debug' USE flag does not apply to the --with-debug
320 # switch (enabling the libxml2 debug module). See bug #100898.
321 -
322 libxml2_configure() {
323 ECONF_SOURCE="${S}" econf \
324 --enable-ipv6 \
325 @@ -160,6 +167,8 @@ multilib_src_install_all() {
326 rm -rf "${ED}"/usr/share/doc/${PF}/python/examples || die
327 fi
328
329 + rm -rf "${ED}"/usr/share/doc/${PN}-python-${PVR} || die
330 +
331 find "${ED}" -name '*.la' -delete || die
332 }