2010-03-13 23:54:19 +08:00
|
|
|
pkgname=libxml2
|
2016-05-27 10:08:59 +08:00
|
|
|
pkgver=2.9.4
|
2015-12-06 18:41:18 +08:00
|
|
|
pkgrel=1
|
2010-03-13 23:54:19 +08:00
|
|
|
pkgdesc="XML parsing library, version 2"
|
2014-06-28 23:20:47 +08:00
|
|
|
arch=('x86_64')
|
2010-03-13 23:54:19 +08:00
|
|
|
license=('custom')
|
2014-06-28 23:20:47 +08:00
|
|
|
depends=('zlib' 'readline' 'ncurses' 'xz')
|
2016-05-27 10:08:59 +08:00
|
|
|
makedepends=('python2' 'python3')
|
2010-03-13 23:54:19 +08:00
|
|
|
url="http://www.xmlsoft.org/"
|
2014-06-28 23:20:47 +08:00
|
|
|
source=(ftp://ftp.xmlsoft.org/${pkgname}/${pkgname}-${pkgver}.tar.gz)
|
2016-05-27 10:08:59 +08:00
|
|
|
md5sums=('ae249165c173b1ff386ee8ad676815f5')
|
2010-03-13 23:54:19 +08:00
|
|
|
|
2016-05-27 10:08:59 +08:00
|
|
|
prepare() {
|
2014-06-28 23:20:47 +08:00
|
|
|
cd "${pkgname}-${pkgver}"
|
2016-05-27 10:08:59 +08:00
|
|
|
mkdir build-py3
|
|
|
|
mkdir build-py2
|
|
|
|
}
|
2014-06-28 23:20:47 +08:00
|
|
|
|
2016-05-27 10:08:59 +08:00
|
|
|
build() {
|
|
|
|
cd "${pkgname}-${pkgver}"
|
|
|
|
|
|
|
|
cd build-py2
|
|
|
|
../configure --prefix=/usr --with-threads --with-history --with-python=/usr/bin/python2
|
|
|
|
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0 /g' libtool
|
2011-01-16 06:40:12 +08:00
|
|
|
make
|
2016-05-27 10:08:59 +08:00
|
|
|
|
|
|
|
cd ../build-py3
|
|
|
|
../configure --prefix=/usr --with-threads --with-history --with-python=/usr/bin/python3
|
|
|
|
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0 /g' libtool
|
|
|
|
PYTHONHASHSEED=0 make
|
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
|
|
|
cd ${srcdir}/${pkgname}-${pkgver}/build-py2
|
|
|
|
make check
|
2011-01-16 06:40:12 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2016-05-27 10:08:59 +08:00
|
|
|
cd ${srcdir}/${pkgname}-${pkgver}/build-py2
|
|
|
|
find doc -type f -exec chmod 0644 {} \;
|
|
|
|
|
2011-01-16 06:40:12 +08:00
|
|
|
make DESTDIR="${pkgdir}" install
|
|
|
|
install -Dm644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
|
2016-05-27 10:08:59 +08:00
|
|
|
|
|
|
|
cd ../build-py3/python
|
|
|
|
PYTHONHASHSEED=0 make DESTDIR="${pkgdir}" install
|
2010-03-13 23:54:19 +08:00
|
|
|
}
|