summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Huemer <alexander.huemer@sbg.ac.at>2009-04-28 15:25:43 +0200
committerAlexander Huemer <alexander.huemer@sbg.ac.at>2009-04-28 15:25:43 +0200
commit23a6422b2a491bedc47d91ccf434780def8dede3 (patch)
tree696551303b3125cc432831ca0c7b41c49d69fe44 /dev-libs/libxml2
parentbumped qt-* to latest ~ (4.5.1) _BUG_ packages ask user (c/o) (diff)
downloadmultilib-portage-23a6422b2a491bedc47d91ccf434780def8dede3.tar.gz
multilib-portage-23a6422b2a491bedc47d91ccf434780def8dede3.tar.bz2
multilib-portage-23a6422b2a491bedc47d91ccf434780def8dede3.zip
bumped dev-libs/libxml2 to latest ~ (2.7.3-r1), not using python_get_sitedir. is this correct. compile errors during byte code compilation. is this overlay related?
Diffstat (limited to 'dev-libs/libxml2')
-rw-r--r--dev-libs/libxml2/Manifest2
-rw-r--r--dev-libs/libxml2/files/libxml2-2.7.3-printf-rename.patch409
-rw-r--r--dev-libs/libxml2/libxml2-2.7.3-r1.ebuild134
3 files changed, 545 insertions, 0 deletions
diff --git a/dev-libs/libxml2/Manifest b/dev-libs/libxml2/Manifest
index 8d4f45948..a36184f70 100644
--- a/dev-libs/libxml2/Manifest
+++ b/dev-libs/libxml2/Manifest
@@ -1,4 +1,6 @@
+AUX libxml2-2.7.3-printf-rename.patch 17280 RMD160 920065d543127026c526f00856e9a2a8fb41e42d SHA1 9a9515a1ea7c7313aa8e6bb607f987560504aaed SHA256 a7206cbd8a675e2d944f330255d648502d143472a2d96daa4753e422614b8520
DIST libxml2-2.7.3.tar.gz 4789450 RMD160 14018347531fd135366cee9fd9d760a1988546e2 SHA1 fd4e427fb55c977876bc74c0e552ef7d3d794a07 SHA256 432464d8c9bd8060d9c1fdef1cfa75803c1a363ceac20b21f8c7e34e056e5a98
DIST xsts-2002-01-16.tar.gz 6894439 RMD160 e8905fe1451a1c367b0104af24edca73bad1db08 SHA1 ca6344e6c47f8c28231f5b213d0c8deb0311a409 SHA256 55e5c08db29946a91ea8e70e8f2418d3fd30d8b6777941dfba7f54726ffd9914
DIST xsts-2004-01-14.tar.gz 2761085 RMD160 faff2d7826e47ae9968564bc83dab1b54c5e4bf6 SHA1 5896c2aa2cda464246306c5cf0577ed506eefaab SHA256 09bdf9f81f381ebf9bc158a9472e498e896f7a02eb7461146e9abe1b9493ca17
+EBUILD libxml2-2.7.3-r1.ebuild 4085 RMD160 0d831a6fe73edbf79569bf8fb7ed3301fe114fa9 SHA1 34a7f446de3f187f7efb799c35e629b443c1c75e SHA256 bd37def4e9fc990ae4df56b5955bc0c1fa6321e04338c971fc51da1bcdd0713e
EBUILD libxml2-2.7.3.ebuild 4007 RMD160 d2145cc9e65384ae51dee960a6e4dd2f6abe12cd SHA1 69925f4b036dd9902ef67183c71ee3ed16fa4767 SHA256 09012594a0acb600ebd9e47a94fcf12e0acc5ed7ddec02dbff073599f3bf63fe
diff --git a/dev-libs/libxml2/files/libxml2-2.7.3-printf-rename.patch b/dev-libs/libxml2/files/libxml2-2.7.3-printf-rename.patch
new file mode 100644
index 000000000..2211a702d
--- /dev/null
+++ b/dev-libs/libxml2/files/libxml2-2.7.3-printf-rename.patch
@@ -0,0 +1,409 @@
+Author: Jose Luis Rivero <yoswink@gentoo.org>
+Source: patch extrated from libxml2 svn. Diff between 3826 .. 3827
+
+Description: the patch fix the problems between libxml2 and wxGTK
+described in http://mail.gnome.org/archives/xml/2009-April/msg00021.html.
+It is basically a renaming of the macro function to avoid collisions
+with other libraries.
+
+This patch should only be applied to version 2.7.3
+
+Index: include/libxml/parser.h
+===================================================================
+--- include/libxml/parser.h (rev: 3826)
++++ include/libxml/parser.h (working copy)
+@@ -594,7 +594,7 @@
+ * Display and format a warning messages, callback.
+ */
+ typedef void (XMLCDECL *warningSAXFunc) (void *ctx,
+- const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++ const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+ /**
+ * errorSAXFunc:
+ * @ctx: an XML parser context
+@@ -604,7 +604,7 @@
+ * Display and format an error messages, callback.
+ */
+ typedef void (XMLCDECL *errorSAXFunc) (void *ctx,
+- const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++ const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+ /**
+ * fatalErrorSAXFunc:
+ * @ctx: an XML parser context
+@@ -616,7 +616,7 @@
+ * get all the callbacks for errors.
+ */
+ typedef void (XMLCDECL *fatalErrorSAXFunc) (void *ctx,
+- const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++ const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+ /**
+ * isStandaloneSAXFunc:
+ * @ctx: the user data (XML parser context)
+Index: include/libxml/xmlwriter.h
+===================================================================
+--- include/libxml/xmlwriter.h (rev: 3826)
++++ include/libxml/xmlwriter.h (working copy)
+@@ -70,12 +70,12 @@
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteFormatComment(xmlTextWriterPtr writer,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(2,3);
++ LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatComment(xmlTextWriterPtr writer,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(2,0);
++ LIBXML_ATTR_FORMAT(2,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteComment(xmlTextWriterPtr
+ writer,
+ const xmlChar *
+@@ -105,13 +105,13 @@
+ xmlTextWriterWriteFormatElement(xmlTextWriterPtr writer,
+ const xmlChar * namme,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(3,4);
++ LIBXML_ATTR_FORMAT(3,4);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatElement(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(3,0);
++ LIBXML_ATTR_FORMAT(3,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteElement(xmlTextWriterPtr
+ writer,
+ const xmlChar * name,
+@@ -123,7 +123,7 @@
+ const xmlChar * name,
+ const xmlChar * namespaceURI,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(5,6);
++ LIBXML_ATTR_FORMAT(5,6);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatElementNS(xmlTextWriterPtr writer,
+ const xmlChar * prefix,
+@@ -131,7 +131,7 @@
+ const xmlChar * namespaceURI,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(5,0);
++ LIBXML_ATTR_FORMAT(5,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteElementNS(xmlTextWriterPtr
+ writer,
+ const xmlChar *
+@@ -148,11 +148,11 @@
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteFormatRaw(xmlTextWriterPtr writer,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(2,3);
++ LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatRaw(xmlTextWriterPtr writer,
+ const char *format, va_list argptr)
+- ATTRIBUTE_PRINTF(2,0);
++ LIBXML_ATTR_FORMAT(2,0);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteRawLen(xmlTextWriterPtr writer,
+ const xmlChar * content, int len);
+@@ -163,13 +163,13 @@
+ writer,
+ const char
+ *format, ...)
+- ATTRIBUTE_PRINTF(2,3);
++ LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteVFormatString(xmlTextWriterPtr
+ writer,
+ const char
+ *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(2,0);
++ LIBXML_ATTR_FORMAT(2,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteString(xmlTextWriterPtr writer,
+ const xmlChar *
+ content);
+@@ -204,13 +204,13 @@
+ xmlTextWriterWriteFormatAttribute(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(3,4);
++ LIBXML_ATTR_FORMAT(3,4);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatAttribute(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(3,0);
++ LIBXML_ATTR_FORMAT(3,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteAttribute(xmlTextWriterPtr
+ writer,
+ const xmlChar * name,
+@@ -222,7 +222,7 @@
+ const xmlChar * name,
+ const xmlChar * namespaceURI,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(5,6);
++ LIBXML_ATTR_FORMAT(5,6);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatAttributeNS(xmlTextWriterPtr writer,
+ const xmlChar * prefix,
+@@ -230,7 +230,7 @@
+ const xmlChar * namespaceURI,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(5,0);
++ LIBXML_ATTR_FORMAT(5,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteAttributeNS(xmlTextWriterPtr
+ writer,
+ const xmlChar *
+@@ -257,12 +257,12 @@
+ xmlTextWriterWriteFormatPI(xmlTextWriterPtr writer,
+ const xmlChar * target,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(3,4);
++ LIBXML_ATTR_FORMAT(3,4);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatPI(xmlTextWriterPtr writer,
+ const xmlChar * target,
+ const char *format, va_list argptr)
+- ATTRIBUTE_PRINTF(3,0);
++ LIBXML_ATTR_FORMAT(3,0);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWritePI(xmlTextWriterPtr writer,
+ const xmlChar * target,
+@@ -287,11 +287,11 @@
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteFormatCDATA(xmlTextWriterPtr writer,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(2,3);
++ LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatCDATA(xmlTextWriterPtr writer,
+ const char *format, va_list argptr)
+- ATTRIBUTE_PRINTF(2,0);
++ LIBXML_ATTR_FORMAT(2,0);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteCDATA(xmlTextWriterPtr writer,
+ const xmlChar * content);
+@@ -315,14 +315,14 @@
+ const xmlChar * pubid,
+ const xmlChar * sysid,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(5,6);
++ LIBXML_ATTR_FORMAT(5,6);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatDTD(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const xmlChar * pubid,
+ const xmlChar * sysid,
+ const char *format, va_list argptr)
+- ATTRIBUTE_PRINTF(5,0);
++ LIBXML_ATTR_FORMAT(5,0);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteDTD(xmlTextWriterPtr writer,
+ const xmlChar * name,
+@@ -353,13 +353,13 @@
+ xmlTextWriterWriteFormatDTDElement(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(3,4);
++ LIBXML_ATTR_FORMAT(3,4);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatDTDElement(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(3,0);
++ LIBXML_ATTR_FORMAT(3,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteDTDElement(xmlTextWriterPtr
+ writer,
+ const xmlChar *
+@@ -383,13 +383,13 @@
+ xmlTextWriterWriteFormatDTDAttlist(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(3,4);
++ LIBXML_ATTR_FORMAT(3,4);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatDTDAttlist(xmlTextWriterPtr writer,
+ const xmlChar * name,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(3,0);
++ LIBXML_ATTR_FORMAT(3,0);
+ XMLPUBFUN int XMLCALL xmlTextWriterWriteDTDAttlist(xmlTextWriterPtr
+ writer,
+ const xmlChar *
+@@ -414,14 +414,14 @@
+ int pe,
+ const xmlChar * name,
+ const char *format, ...)
+- ATTRIBUTE_PRINTF(4,5);
++ LIBXML_ATTR_FORMAT(4,5);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteVFormatDTDInternalEntity(xmlTextWriterPtr writer,
+ int pe,
+ const xmlChar * name,
+ const char *format,
+ va_list argptr)
+- ATTRIBUTE_PRINTF(4,0);
++ LIBXML_ATTR_FORMAT(4,0);
+ XMLPUBFUN int XMLCALL
+ xmlTextWriterWriteDTDInternalEntity(xmlTextWriterPtr writer,
+ int pe,
+Index: include/libxml/relaxng.h
+===================================================================
+--- include/libxml/relaxng.h (rev: 3826)
++++ include/libxml/relaxng.h (working copy)
+@@ -32,7 +32,7 @@
+ *
+ * Signature of an error callback from a Relax-NG validation
+ */
+-typedef void (XMLCDECL *xmlRelaxNGValidityErrorFunc) (void *ctx, const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++typedef void (XMLCDECL *xmlRelaxNGValidityErrorFunc) (void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+
+ /**
+ * xmlRelaxNGValidityWarningFunc:
+@@ -42,7 +42,7 @@
+ *
+ * Signature of a warning callback from a Relax-NG validation
+ */
+-typedef void (XMLCDECL *xmlRelaxNGValidityWarningFunc) (void *ctx, const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++typedef void (XMLCDECL *xmlRelaxNGValidityWarningFunc) (void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+
+ /**
+ * A schemas validation context
+Index: include/libxml/xmlversion.h.in
+===================================================================
+--- include/libxml/xmlversion.h.in (rev: 3826)
++++ include/libxml/xmlversion.h.in (working copy)
+@@ -414,19 +414,19 @@
+ #endif
+
+ /**
+- * ATTRIBUTE_PRINTF:
++ * LIBXML_ATTR_FORMAT:
+ *
+ * Macro used to indicate to GCC the parameter are printf like
+ */
+
+-#ifndef ATTRIBUTE_PRINTF
++#ifndef LIBXML_ATTR_FORMAT
+ # if ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)))
+-# define ATTRIBUTE_PRINTF(fmt,args) __attribute__((__format__(__printf__,fmt,args)))
++# define LIBXML_ATTR_FORMAT(fmt,args) __attribute__((__format__(__printf__,fmt,args)))
+ # else
+-# define ATTRIBUTE_PRINTF(fmt,args)
++# define LIBXML_ATTR_FORMAT(fmt,args)
+ # endif
+ #else
+-# define ATTRIBUTE_PRINTF(fmt,args)
++# define LIBXML_ATTR_FORMAT(fmt,args)
+ #endif
+
+ #else /* ! __GNUC__ */
+@@ -443,11 +443,11 @@
+ */
+ #define ATTRIBUTE_ALLOC_SIZE(x)
+ /**
+- * ATTRIBUTE_PRINTF:
++ * LIBXML_ATTR_FORMAT:
+ *
+ * Macro used to indicate to GCC the parameter are printf like
+ */
+-#define ATTRIBUTE_PRINTF(fmt,args)
++#define LIBXML_ATTR_FORMAT(fmt,args)
+ #endif /* __GNUC__ */
+
+ #ifdef __cplusplus
+
+Index: include/libxml/valid.h
+===================================================================
+--- include/libxml/valid.h (rev: 3826)
++++ include/libxml/valid.h (working copy)
+@@ -41,7 +41,7 @@
+ */
+ typedef void (XMLCDECL *xmlValidityErrorFunc) (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+
+ /**
+ * xmlValidityWarningFunc:
+@@ -56,7 +56,7 @@
+ */
+ typedef void (XMLCDECL *xmlValidityWarningFunc) (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+
+ #ifdef IN_LIBXML
+ /**
+Index: include/libxml/xmlschemas.h
+===================================================================
+--- include/libxml/xmlschemas.h (rev: 3826)
++++ include/libxml/xmlschemas.h (working copy)
+@@ -92,7 +92,7 @@
+ *
+ * Signature of an error callback from an XSD validation
+ */
+-typedef void (XMLCDECL *xmlSchemaValidityErrorFunc) (void *ctx, const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++typedef void (XMLCDECL *xmlSchemaValidityErrorFunc) (void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+
+ /**
+ * xmlSchemaValidityWarningFunc:
+@@ -102,7 +102,7 @@
+ *
+ * Signature of a warning callback from an XSD validation
+ */
+-typedef void (XMLCDECL *xmlSchemaValidityWarningFunc) (void *ctx, const char *msg, ...) ATTRIBUTE_PRINTF(2,3);
++typedef void (XMLCDECL *xmlSchemaValidityWarningFunc) (void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
+
+ /**
+ * A schemas validation context
+Index: include/libxml/xmlerror.h
+===================================================================
+--- include/libxml/xmlerror.h (rev: 3826)
++++ include/libxml/xmlerror.h (working copy)
+@@ -843,7 +843,7 @@
+ */
+ typedef void (XMLCDECL *xmlGenericErrorFunc) (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+ /**
+ * xmlStructuredErrorFunc:
+ * @userData: user provided data for the error callback
+@@ -874,19 +874,19 @@
+ XMLPUBFUN void XMLCDECL
+ xmlParserError (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN void XMLCDECL
+ xmlParserWarning (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN void XMLCDECL
+ xmlParserValidityError (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN void XMLCDECL
+ xmlParserValidityWarning (void *ctx,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(2,3);
++ ...) LIBXML_ATTR_FORMAT(2,3);
+ XMLPUBFUN void XMLCALL
+ xmlParserPrintFileInfo (xmlParserInputPtr input);
+ XMLPUBFUN void XMLCALL
+@@ -930,7 +930,7 @@
+ int int1,
+ int col,
+ const char *msg,
+- ...) ATTRIBUTE_PRINTF(16,17);
++ ...) LIBXML_ATTR_FORMAT(16,17);
+ XMLPUBFUN void XMLCALL
+ __xmlSimpleError (int domain,
+ int code,
diff --git a/dev-libs/libxml2/libxml2-2.7.3-r1.ebuild b/dev-libs/libxml2/libxml2-2.7.3-r1.ebuild
new file mode 100644
index 000000000..9aff06dc7
--- /dev/null
+++ b/dev-libs/libxml2/libxml2-2.7.3-r1.ebuild
@@ -0,0 +1,134 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxml2/libxml2-2.7.3.ebuild,v 1.9 2009/03/18 18:06:10 jer Exp $
+
+EAPI="2"
+
+inherit libtool flag-o-matic eutils python multilib-native
+
+DESCRIPTION="Version 2 of the library to manipulate XML files"
+HOMEPAGE="http://www.xmlsoft.org/"
+
+LICENSE="MIT"
+SLOT="2"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
+IUSE="debug doc examples ipv6 python readline test"
+
+XSTS_HOME="http://www.w3.org/XML/2004/xml-schema-test-suite"
+XSTS_NAME_1="xmlschema2002-01-16"
+XSTS_NAME_2="xmlschema2004-01-14"
+XSTS_TARBALL_1="xsts-2002-01-16.tar.gz"
+XSTS_TARBALL_2="xsts-2004-01-14.tar.gz"
+
+SRC_URI="ftp://xmlsoft.org/${PN}/${P}.tar.gz
+ test? (
+ ${XSTS_HOME}/${XSTS_NAME_1}/${XSTS_TARBALL_1}
+ ${XSTS_HOME}/${XSTS_NAME_2}/${XSTS_TARBALL_2} )"
+
+RDEPEND="sys-libs/zlib
+ python? ( dev-lang/python[lib32?] )
+ readline? ( sys-libs/readline[lib32?] )"
+
+DEPEND="${RDEPEND}
+ hppa? ( >=sys-devel/binutils-2.15.92.0.2 )"
+
+src_unpack() {
+ # ${A} isn't used to avoid unpacking of test tarballs into $WORKDIR,
+ # as they are needed as tarballs in ${S}/xstc instead and not unpacked
+ unpack ${P}.tar.gz
+ cd "${S}"
+
+ if use test; then
+ cp "${DISTDIR}/${XSTS_TARBALL_1}" \
+ "${DISTDIR}/${XSTS_TARBALL_2}" \
+ "${S}"/xstc/ \
+ || die "Failed to install test tarballs"
+ fi
+ # Fix macro conflict with wxGTK, bug #266653
+ epatch "${FILESDIR}/${P}-printf-rename.patch"
+
+ epunt_cxx
+}
+
+multilib-native_src_configure_internal() {
+ # USE zlib support breaks gnome2
+ # (libgnomeprint for instance fails to compile with
+ # fresh install, and existing) - <azarah@gentoo.org> (22 Dec 2002).
+
+ # The meaning of the 'debug' USE flag does not apply to the --with-debug
+ # switch (enabling the libxml2 debug module). See bug #100898.
+
+ # --with-mem-debug causes unusual segmentation faults (bug #105120).
+
+ local myconf="--with-zlib \
+ $(use_with debug run-debug) \
+ $(use_with python) \
+ $(use_with readline) \
+ $(use_with readline history) \
+ $(use_enable ipv6)"
+
+ # Please do not remove, as else we get references to PORTAGE_TMPDIR
+ # in /usr/lib/python?.?/site-packages/libxml2mod.la among things.
+ elibtoolize
+
+ # filter seemingly problematic CFLAGS (#26320)
+ filter-flags -fprefetch-loop-arrays -funroll-loops
+
+ econf $myconf
+
+ # Patching the Makefiles to respect get_libdir
+ # Fixes BUG #86766, please keep this.
+ # Danny van Dyk <kugelfang@gentoo.org> 2005/03/26
+ for x in $(find "${S}" -name "Makefile") ; do
+ sed \
+ -e "s|^\(PYTHON_SITE_PACKAGES\ =\ \/usr\/\).*\(\/python.*\)|\1$(get_libdir)\2|g" \
+ -i ${x} \
+ || die "sed failed"
+ done
+}
+
+multilib-native_src_install_internal() {
+ emake DESTDIR="${D}" install || die "Installation failed"
+
+ dodoc AUTHORS ChangeLog Copyright NEWS README* TODO* || die "dodoc failed"
+
+ if ! use doc; then
+ rm -rf "${D}"/usr/share/gtk-doc
+ rm -rf "${D}"/usr/share/doc/${P}/html
+ fi
+
+ if ! use examples; then
+ rm -rf "${D}/usr/share/doc/${P}/examples"
+ rm -rf "${D}/usr/share/doc/${PN}-python-${PV}/examples"
+ fi
+}
+
+multilib-native_pkg_postinst_internal() {
+ if use python; then
+ python_need_rebuild
+ python_mod_optimize /usr/$(get_libdir)/python${PYVER}/site-packages
+ fi
+
+ # We don't want to do the xmlcatalog during stage1, as xmlcatalog will not
+ # be in / and stage1 builds to ROOT=/tmp/stage1root. This fixes bug #208887.
+ if [ "${ROOT}" != "/" ]
+ then
+ elog "Skipping XML catalog creation for stage building (bug #208887)."
+ else
+ # need an XML catalog, so no-one writes to a non-existent one
+ CATALOG="${ROOT}etc/xml/catalog"
+
+ # we dont want to clobber an existing catalog though,
+ # only ensure that one is there
+ # <obz@gentoo.org>
+ if [ ! -e ${CATALOG} ]; then
+ [ -d "${ROOT}etc/xml" ] || mkdir -p "${ROOT}etc/xml"
+ /usr/bin/xmlcatalog --create > ${CATALOG}
+ einfo "Created XML catalog in ${CATALOG}"
+ fi
+ fi
+}
+
+multilib-native_pkg_postrm_internal() {
+ python_mod_cleanup /usr/$(get_libdir)/python*/site-packages
+}