1 |
tetromino 12/05/26 07:58:15 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: libxml2-2.8.0-r1.ebuild |
5 |
Removed: libxml2-2.8.0.ebuild |
6 |
Log: |
7 |
Prevent libxml2's python module from linking to out-of-build-tree libxml2 library by hacking the relink_command entry in its build-time .la file. Fixes bug #417539 ("'LIBXML2_2.7.9' not found" errors). Forced to drop hppa and amd64-fbsd keywords, bug #417569. Drop broken 2.8.0 ebuild. |
8 |
|
9 |
(Portage version: 2.2.0_alpha108/cvs/Linux x86_64) |
10 |
|
11 |
Revision Changes Path |
12 |
1.346 dev-libs/libxml2/ChangeLog |
13 |
|
14 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libxml2/ChangeLog?rev=1.346&view=markup |
15 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libxml2/ChangeLog?rev=1.346&content-type=text/plain |
16 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libxml2/ChangeLog?r1=1.345&r2=1.346 |
17 |
|
18 |
Index: ChangeLog |
19 |
=================================================================== |
20 |
RCS file: /var/cvsroot/gentoo-x86/dev-libs/libxml2/ChangeLog,v |
21 |
retrieving revision 1.345 |
22 |
retrieving revision 1.346 |
23 |
diff -u -r1.345 -r1.346 |
24 |
--- ChangeLog 25 May 2012 07:13:52 -0000 1.345 |
25 |
+++ ChangeLog 26 May 2012 07:58:15 -0000 1.346 |
26 |
@@ -1,6 +1,15 @@ |
27 |
# ChangeLog for dev-libs/libxml2 |
28 |
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 |
29 |
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxml2/ChangeLog,v 1.345 2012/05/25 07:13:52 tetromino Exp $ |
30 |
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxml2/ChangeLog,v 1.346 2012/05/26 07:58:15 tetromino Exp $ |
31 |
+ |
32 |
+*libxml2-2.8.0-r1 (26 May 2012) |
33 |
+ |
34 |
+ 26 May 2012; Alexandre Rostovtsev <tetromino@g.o> |
35 |
+ -libxml2-2.8.0.ebuild, +libxml2-2.8.0-r1.ebuild: |
36 |
+ Prevent libxml2's python module from linking to out-of-build-tree libxml2 |
37 |
+ library by hacking the relink_command entry in its build-time .la file. Fixes |
38 |
+ bug #417539 ("'LIBXML2_2.7.9' not found" errors). Forced to drop hppa and |
39 |
+ amd64-fbsd keywords, bug #417569. Drop broken 2.8.0 ebuild. |
40 |
|
41 |
*libxml2-2.8.0 (25 May 2012) |
42 |
|
43 |
|
44 |
|
45 |
|
46 |
1.1 dev-libs/libxml2/libxml2-2.8.0-r1.ebuild |
47 |
|
48 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libxml2/libxml2-2.8.0-r1.ebuild?rev=1.1&view=markup |
49 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libxml2/libxml2-2.8.0-r1.ebuild?rev=1.1&content-type=text/plain |
50 |
|
51 |
Index: libxml2-2.8.0-r1.ebuild |
52 |
=================================================================== |
53 |
# Copyright 1999-2012 Gentoo Foundation |
54 |
# Distributed under the terms of the GNU General Public License v2 |
55 |
# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxml2/libxml2-2.8.0-r1.ebuild,v 1.1 2012/05/26 07:58:15 tetromino Exp $ |
56 |
|
57 |
EAPI="4" |
58 |
PYTHON_DEPEND="python? 2" |
59 |
PYTHON_USE_WITH="xml" |
60 |
PYTHON_USE_WITH_OPT="python" |
61 |
SUPPORT_PYTHON_ABIS="1" |
62 |
RESTRICT_PYTHON_ABIS="3.* *-jython 2.7-pypy-*" |
63 |
|
64 |
inherit libtool flag-o-matic eutils python autotools prefix |
65 |
|
66 |
DESCRIPTION="Version 2 of the library to manipulate XML files" |
67 |
HOMEPAGE="http://www.xmlsoft.org/" |
68 |
|
69 |
LICENSE="MIT" |
70 |
SLOT="2" |
71 |
KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~hppa-hpux ~ia64-hpux ~x86-interix ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris ~x86-winnt" |
72 |
IUSE="debug doc examples icu ipv6 lzma python readline static-libs test" |
73 |
|
74 |
XSTS_HOME="http://www.w3.org/XML/2004/xml-schema-test-suite" |
75 |
XSTS_NAME_1="xmlschema2002-01-16" |
76 |
XSTS_NAME_2="xmlschema2004-01-14" |
77 |
XSTS_TARBALL_1="xsts-2002-01-16.tar.gz" |
78 |
XSTS_TARBALL_2="xsts-2004-01-14.tar.gz" |
79 |
|
80 |
SRC_URI="ftp://xmlsoft.org/${PN}/${PN}-${PV/_rc/-rc}.tar.gz |
81 |
test? ( |
82 |
${XSTS_HOME}/${XSTS_NAME_1}/${XSTS_TARBALL_1} |
83 |
${XSTS_HOME}/${XSTS_NAME_2}/${XSTS_TARBALL_2} )" |
84 |
|
85 |
RDEPEND="sys-libs/zlib |
86 |
icu? ( dev-libs/icu ) |
87 |
lzma? ( app-arch/xz-utils ) |
88 |
readline? ( sys-libs/readline )" |
89 |
|
90 |
DEPEND="${RDEPEND} |
91 |
python? ( dev-util/fix-la-relink-command ) |
92 |
hppa? ( >=sys-devel/binutils-2.15.92.0.2 )" |
93 |
|
94 |
S="${WORKDIR}/${PN}-${PV%_rc*}" |
95 |
|
96 |
pkg_setup() { |
97 |
use python && python_pkg_setup |
98 |
} |
99 |
|
100 |
src_unpack() { |
101 |
# ${A} isn't used to avoid unpacking of test tarballs into $WORKDIR, |
102 |
# as they are needed as tarballs in ${S}/xstc instead and not unpacked |
103 |
unpack ${P/_rc/-rc}.tar.gz |
104 |
cd "${S}" |
105 |
|
106 |
if use test; then |
107 |
cp "${DISTDIR}/${XSTS_TARBALL_1}" \ |
108 |
"${DISTDIR}/${XSTS_TARBALL_2}" \ |
109 |
"${S}"/xstc/ \ |
110 |
|| die "Failed to install test tarballs" |
111 |
fi |
112 |
} |
113 |
|
114 |
src_prepare() { |
115 |
# Patches needed for prefix support |
116 |
epatch "${FILESDIR}"/${PN}-2.7.1-catalog_path.patch |
117 |
epatch "${FILESDIR}"/${PN}-2.8.0_rc1-winnt.patch |
118 |
|
119 |
eprefixify catalog.c xmlcatalog.c runtest.c xmllint.c |
120 |
|
121 |
epunt_cxx |
122 |
|
123 |
epatch "${FILESDIR}/${PN}-2.7.8-disable_static_modules.patch" |
124 |
|
125 |
# Please do not remove, as else we get references to PORTAGE_TMPDIR |
126 |
# in /usr/lib/python?.?/site-packages/libxml2mod.la among things. |
127 |
# We now need to run eautoreconf at the end to prevent maintainer mode. |
128 |
# elibtoolize |
129 |
|
130 |
# Python bindings are built/tested/installed manually. |
131 |
sed -e "s/@PYTHON_SUBDIR@//" -i Makefile.am || die "sed 1 failed" |
132 |
|
133 |
# Use Gentoo's python-config naming scheme |
134 |
sed -e 's/python$PYTHON_VERSION-config/python-config-$PYTHON_VERSION/' \ |
135 |
-i configure.in || die "sed 2 failed" |
136 |
|
137 |
eautoreconf |
138 |
} |
139 |
|
140 |
src_configure() { |
141 |
# USE zlib support breaks gnome2 |
142 |
# (libgnomeprint for instance fails to compile with |
143 |
# fresh install, and existing) - <azarah@g.o> (22 Dec 2002). |
144 |
|
145 |
# The meaning of the 'debug' USE flag does not apply to the --with-debug |
146 |
# switch (enabling the libxml2 debug module). See bug #100898. |
147 |
|
148 |
# --with-mem-debug causes unusual segmentation faults (bug #105120). |
149 |
|
150 |
local myconf=( |
151 |
--with-html-subdir=${PF}/html |
152 |
--docdir="${EPREFIX}/usr/share/doc/${PF}" |
153 |
$(use_with debug run-debug) |
154 |
$(use_with icu) |
155 |
$(use_with lzma) |
156 |
$(use_with python) |
157 |
$(use_with readline) |
158 |
$(use_with readline history) |
159 |
$(use_enable ipv6) |
160 |
$(use_enable static-libs static) ) |
161 |
|
162 |
# filter seemingly problematic CFLAGS (#26320) |
163 |
filter-flags -fprefetch-loop-arrays -funroll-loops |
164 |
|
165 |
econf "${myconf[@]}" |
166 |
} |
167 |
|
168 |
src_compile() { |
169 |
default |
170 |
|
171 |
if use python; then |
172 |
python_copy_sources python |
173 |
building() { |
174 |
emake PYTHON_INCLUDES="${EPREFIX}$(python_get_includedir)" \ |
175 |
PYTHON_SITE_PACKAGES="${EPREFIX}$(python_get_sitedir)" |
176 |
} |
177 |
python_execute_function -s --source-dir python building |
178 |
fi |
179 |
} |
180 |
|
181 |
src_test() { |
182 |
default |
183 |
|
184 |
if use python; then |
185 |
testing() { |
186 |
emake test |
187 |
} |
188 |
python_execute_function -s --source-dir python testing |
189 |
fi |
190 |
} |
191 |
|
192 |
src_install() { |
193 |
emake DESTDIR="${D}" \ |
194 |
EXAMPLES_DIR="${EPREFIX}"/usr/share/doc/${PF}/examples \ |
195 |
install || die "Installation failed" |
196 |
|
197 |
# on windows, xmllint is installed by interix libxml2 in parent prefix. |
198 |
# this is the version to use. the native winnt version does not support |
199 |
# symlinks, which makes repoman fail if the portage tree is linked in |
200 |
# from another location (which is my default). -- mduft |
201 |
if [[ ${CHOST} == *-winnt* ]]; then |
202 |
rm -rf "${ED}"/usr/bin/xmllint |
203 |
rm -rf "${ED}"/usr/bin/xmlcatalog |
204 |
fi |
205 |
|
206 |
if use python; then |
207 |
installation() { |
208 |
# bug #417539 |
209 |
fix-la-relink-command . || die "fix-la-relink-command failed" |
210 |
emake DESTDIR="${D}" \ |
211 |
PYTHON_SITE_PACKAGES="${EPREFIX}$(python_get_sitedir)" \ |
212 |
docsdir="${EPREFIX}"/usr/share/doc/${PF}/python \ |
213 |
exampledir="${EPREFIX}"/usr/share/doc/${PF}/python/examples \ |
214 |
install |
215 |
} |
216 |
python_execute_function -s --source-dir python installation |
217 |
|
218 |
python_clean_installation_image |
219 |
fi |
220 |
|
221 |
rm -rf "${ED}"/usr/share/doc/${P} |
222 |
dodoc AUTHORS ChangeLog Copyright NEWS README* TODO* |
223 |
|
224 |
if ! use python; then |
225 |
rm -rf "${ED}"/usr/share/doc/${PF}/python |
226 |
rm -rf "${ED}"/usr/share/doc/${PN}-python-${PV} |
227 |
fi |
228 |
|
229 |
if ! use doc; then |
230 |
rm -rf "${ED}"/usr/share/gtk-doc |
231 |
rm -rf "${ED}"/usr/share/doc/${PF}/html |
232 |
fi |
233 |
|
234 |
if ! use examples; then |
235 |
rm -rf "${ED}/usr/share/doc/${PF}/examples" |
236 |
rm -rf "${ED}/usr/share/doc/${PF}/python/examples" |
237 |
fi |
238 |
|
239 |
# Always remove useless .la files |
240 |
find "${D}" -name '*.la' -exec rm -f {} + || die "la file removal failed" |
241 |
} |
242 |
|
243 |
pkg_postinst() { |
244 |
if use python; then |
245 |
python_mod_optimize drv_libxml2.py libxml2.py |
246 |
fi |
247 |
|
248 |
# We don't want to do the xmlcatalog during stage1, as xmlcatalog will not |
249 |
# be in / and stage1 builds to ROOT=/tmp/stage1root. This fixes bug #208887. |
250 |
if [ "${ROOT}" != "/" ] |
251 |
then |
252 |
elog "Skipping XML catalog creation for stage building (bug #208887)." |
253 |
else |
254 |
# need an XML catalog, so no-one writes to a non-existent one |
255 |
CATALOG="${EROOT}etc/xml/catalog" |
256 |
|
257 |
# we dont want to clobber an existing catalog though, |
258 |
# only ensure that one is there |
259 |
# <obz@g.o> |
260 |
if [ ! -e ${CATALOG} ]; then |
261 |
[ -d "${EROOT}etc/xml" ] || mkdir -p "${EROOT}etc/xml" |
262 |
"${EPREFIX}"/usr/bin/xmlcatalog --create > ${CATALOG} |
263 |
einfo "Created XML catalog in ${CATALOG}" |
264 |
fi |
265 |
fi |
266 |
} |
267 |
|
268 |
pkg_postrm() { |
269 |
if use python; then |
270 |
python_mod_cleanup drv_libxml2.py libxml2.py |
271 |
fi |
272 |
} |