1 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
2 # Maintainer: Rémy Oudompheng <remy@archlinux.org>
4 pkgname=python-pyelftools
8 pkgdesc='Python library for analyzing ELF files and DWARF debugging information'
9 url='https://github.com/eliben/pyelftools'
11 license=('custom:Public Domain')
12 makedepends=('python' 'python-setuptools')
15 source=(https://github.com/eliben/${_pkgname}/archive/v${pkgver}/${_pkgname}-${pkgver}.tar.gz)
16 sha512sums=('bb0a00e5500016e3d4f64be0a728e190f84b11a805f78d668b5a74716a30400e6794946f198ef4a3f3b8f64a63deb1b5a96180b09e56b7357b988b28e25fad0a')
17 b2sums=('74e6e17c68b197d0ecdddedba81a96601003c41a9c095bc72dff7630511705d36d1bc2732005a87ad1420c99497d729c5b771eca7bf5409c0da77d7b348d9c1b')
21 cd ${_pkgname}-${pkgver}
26 cd ${_pkgname}-${pkgver}
27 python test/run_all_unittests.py
28 python test/run_examples_test.py
29 if [ "${CARCH}" == "x86_64" ]; then
30 python test/run_readelf_tests.py
32 echo "Skipping readelf tests (require x86_64)"
37 cd ${_pkgname}-${pkgver}
38 python setup.py install -O1 --root="${pkgdir}" --skip-build
39 install -Dm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
40 install -Dm 644 README.rst CHANGES -t "${pkgdir}/usr/share/doc/${pkgname}"
41 cp -r examples "${pkgdir}/usr/share/doc/${pkgname}"