# Contributor: Carlo Landmeter # Maintainer: Carlo Landmeter pkgname=libxml2 pkgver=2.7.8 pkgrel=6 pkgdesc="XML parsing library, version 2" url="http://www.xmlsoft.org/" arch="all" license="MIT" depends= depends_dev="zlib-dev python-dev" makedepends="zlib-dev python-dev" subpackages="$pkgname-doc $pkgname-dev py-$pkgname:py $pkgname-utils" source="ftp://ftp.xmlsoft.org/${pkgname}/${pkgname}-${pkgver}.tar.gz largefile64.patch libxml2-2.7.8-CVE-2011-1944.patch cve-2012-0841.patch libxml2-2.7.8-xpath-memory.patch libxml2-2.7.8-xpath-freeing.patch libxml2-2.7.8-xpath-freeing2.patch libxml2-2.7.8-hardening-xpath.patch libxml2-2.7.8-error-xpath.patch libxml2-2.7.8-allocation-error-copying-entities.patch libxml2-2.7.8-entities-local-buffers-size.patch libxml2-2.7.8-entities-local-buffers-size2.patch libxml2-2.7.8-parser-local-buffers-size.patch CVE-2012-5134.patch CVE-2013-0338.patch " options="!strip" _builddir="$srcdir/$pkgname-$pkgver" prepare() { cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { cd "$_builddir" ./configure --prefix=/usr \ --sysconfdir=/etc \ --mandir=/usr/share/man \ --infodir=/usr/share/info make } package() { cd "$_builddir" make -j1 DESTDIR="$pkgdir" install install -Dm644 COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING } py() { cd "$_builddir" pkgdesc="$pkgname python bindings" install -d "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/ } utils() { pkgdesc="XML utilities" replaces="libxml2" mkdir -p "$subpkgdir"/usr mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ } md5sums="8127a65e8c3b08856093099b52599c86 libxml2-2.7.8.tar.gz 5ad4915665608ebfa5b89f7908467a72 largefile64.patch 49cba5245dfa6f2ec710324df947fff9 libxml2-2.7.8-CVE-2011-1944.patch 045c7f25e46de3127a6061e273de3f7b cve-2012-0841.patch bec456883fa9c91b0e7d2ad91283eeb1 libxml2-2.7.8-xpath-memory.patch 8e3374d282fc12c7e40a3c5fb4b62978 libxml2-2.7.8-xpath-freeing.patch d1eff47d3bc99b38a09744345eaf3434 libxml2-2.7.8-xpath-freeing2.patch 9027cbb76b112629cb5fa84ffcfc44bd libxml2-2.7.8-hardening-xpath.patch 8bf2bd2422b9aab015fb7a8ca993eef3 libxml2-2.7.8-error-xpath.patch de02f584b928d3e25babc5c90aa800be libxml2-2.7.8-allocation-error-copying-entities.patch c8c789a4fbdae599a47ecbfa32b889d7 libxml2-2.7.8-entities-local-buffers-size.patch cba1201e77dc0f3e337d9ff146a2666e libxml2-2.7.8-entities-local-buffers-size2.patch 6c5c7a125dddb616feb1b2f4254bf467 libxml2-2.7.8-parser-local-buffers-size.patch fe428448d74481d7547bc173cb40ef26 CVE-2012-5134.patch 5eb19e0b5107a9ee6cca8a5f04b44b77 CVE-2013-0338.patch"