diff options
author | Daniel Gryniewicz <dang@gentoo.org> | 2007-08-29 15:13:01 +0000 |
---|---|---|
committer | Daniel Gryniewicz <dang@gentoo.org> | 2007-08-29 15:13:01 +0000 |
commit | 129f253e23d09ce58f6f4e568fb57966d76a89a1 (patch) | |
tree | b64ae56cb9d55cefc6cdb5e72ad26cfe480af43f | |
parent | stable 0.20.2 for Schedules Direct support needed by Sept 1 (diff) | |
download | gentoo-2-129f253e23d09ce58f6f4e568fb57966d76a89a1.tar.gz gentoo-2-129f253e23d09ce58f6f4e568fb57966d76a89a1.tar.bz2 gentoo-2-129f253e23d09ce58f6f4e568fb57966d76a89a1.zip |
Zero out allocated memory, to fix a core on amd64. Bug #190388
(Portage version: 2.1.3.7)
-rw-r--r-- | dev-libs/libxslt/ChangeLog | 8 | ||||
-rw-r--r-- | dev-libs/libxslt/files/digest-libxslt-1.1.20-r1 | 3 | ||||
-rw-r--r-- | dev-libs/libxslt/files/libxslt-1.1.20-amd64.patch | 29 | ||||
-rw-r--r-- | dev-libs/libxslt/libxslt-1.1.20-r1.ebuild | 67 |
4 files changed, 106 insertions, 1 deletions
diff --git a/dev-libs/libxslt/ChangeLog b/dev-libs/libxslt/ChangeLog index bb4c0928e00a..922045cd8a9a 100644 --- a/dev-libs/libxslt/ChangeLog +++ b/dev-libs/libxslt/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for dev-libs/libxslt # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxslt/ChangeLog,v 1.154 2007/06/02 02:44:54 ranger Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxslt/ChangeLog,v 1.155 2007/08/29 15:13:01 dang Exp $ + +*libxslt-1.1.20-r1 (29 Aug 2007) + + 29 Aug 2007; Daniel Gryniewicz <dang@gentoo.org> + +files/libxslt-1.1.20-amd64.patch, +libxslt-1.1.20-r1.ebuild: + Zero out allocated memory, to fix a core on amd64. Bug #190388 02 Jun 2007; Brent Baude <ranger@gentoo.org> libxslt-1.1.20.ebuild: Marking libxslt-1.1.20 ppc stable for bug #171107 diff --git a/dev-libs/libxslt/files/digest-libxslt-1.1.20-r1 b/dev-libs/libxslt/files/digest-libxslt-1.1.20-r1 new file mode 100644 index 000000000000..5432130408ce --- /dev/null +++ b/dev-libs/libxslt/files/digest-libxslt-1.1.20-r1 @@ -0,0 +1,3 @@ +MD5 4ea2dc22a23bf2aa570f868aa86357f8 libxslt-1.1.20.tar.gz 3689759 +RMD160 f2882ff47312de3b6317136ef751d4b42ab15a53 libxslt-1.1.20.tar.gz 3689759 +SHA256 ce92f00031c885e04cb65ea76c4675b07aa98af9607572fb0d68180c34bf5346 libxslt-1.1.20.tar.gz 3689759 diff --git a/dev-libs/libxslt/files/libxslt-1.1.20-amd64.patch b/dev-libs/libxslt/files/libxslt-1.1.20-amd64.patch new file mode 100644 index 000000000000..ab9b4766c18d --- /dev/null +++ b/dev-libs/libxslt/files/libxslt-1.1.20-amd64.patch @@ -0,0 +1,29 @@ +diff --exclude-from=/home/dang/.scripts/diffrc -up -ruN libxslt-1.1.20.orig/python/libxslt.c libxslt-1.1.20/python/libxslt.c +--- libxslt-1.1.20.orig/python/libxslt.c 2007-01-15 07:51:48.000000000 -0500 ++++ libxslt-1.1.20/python/libxslt.c 2007-08-29 10:36:36.000000000 -0400 +@@ -740,7 +740,7 @@ libxslt_xsltApplyStylesheet(PyObject *se + PyObject *pyobj_doc; + PyObject *pyobj_params; + const char **params = NULL; +- int len = 0, i = 0, j; ++ int len = 0, i = 0, j, params_size; + PyObject *name; + PyObject *value; + +@@ -752,13 +752,14 @@ libxslt_xsltApplyStylesheet(PyObject *se + if (PyDict_Check(pyobj_params)) { + len = PyDict_Size(pyobj_params); + if (len > 0) { +- params = (const char **) xmlMalloc((len + 1) * 2 * +- sizeof(char *)); ++ params_size = (len + 1) * 2 * sizeof(char *); ++ params = (const char **) xmlMalloc(params_size); + if (params == NULL) { + printf("libxslt_xsltApplyStylesheet: out of memory\n"); + Py_INCREF(Py_None); + return(Py_None); + } ++ memset(params, 0, params_size); + j = 0; + while (PyDict_Next(pyobj_params, &i, &name, &value)) { + const char *tmp; diff --git a/dev-libs/libxslt/libxslt-1.1.20-r1.ebuild b/dev-libs/libxslt/libxslt-1.1.20-r1.ebuild new file mode 100644 index 000000000000..a48e7025592b --- /dev/null +++ b/dev-libs/libxslt/libxslt-1.1.20-r1.ebuild @@ -0,0 +1,67 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/libxslt/libxslt-1.1.20-r1.ebuild,v 1.1 2007/08/29 15:13:01 dang Exp $ + +inherit libtool eutils python + +DESCRIPTION="XSLT libraries and tools" +HOMEPAGE="http://www.xmlsoft.org/" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd" +IUSE="crypt debug python" + +DEPEND=">=dev-libs/libxml2-2.6.27 + crypt? ( >=dev-libs/libgcrypt-1.1.92 ) + python? ( dev-lang/python )" + +SRC_URI="ftp://xmlsoft.org/${PN}/${P}.tar.gz" + +src_unpack() { + unpack "${A}" + cd "${S}" + + # we still require the 1.1.8 patch for the .m4 file, to add + # the CXXFLAGS defines <obz@gentoo.org> + epatch "${FILESDIR}"/libxslt.m4-${PN}-1.1.8.patch + + # Using the python bindings causes a core; bug #190388 + epatch "${FILESDIR}"/${P}-amd64.patch + + # Patch Makefile to fix bug #99382 so that html gets installed in ${PF} + sed -i -e 's:libxslt-$(VERSION):${PF}:' doc/Makefile.in + + epunt_cxx + elibtoolize +} + +src_compile() { + # Always pass --with-debugger. It is required by third parties (see + # e.g. bug #98345) + local myconf="--with-debugger \ + $(use_with python) \ + $(use_with crypt crypto) \ + $(use_with debug) \ + $(use_with debug mem-debug)" + + econf ${myconf} || die "configure failed" + + # Patching the Makefiles to respect get_libdir + # Fixes BUG #86756, 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 + + emake || die "Compilation failed" +} + +src_install() { + make DESTDIR="${D}" install || die "Installation failed" + + dodoc AUTHORS ChangeLog Copyright FEATURES NEWS README TODO +} |