blob: a49836b4546421d3621f49e72e74d08d27be402c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
# Description: Python library for analyzing ELF files and DWARF debugging information
# URL: https://github.com/eliben/pyelftools
# Maintainer: Erich Eckner, crux at eckner dot net
# Depends on: python3-build python3-installer python3-wheel python3-setuptools
name=python3-pyelftools
version=0.29
release=1
source=("https://github.com/eliben/pyelftools/archive/v${version}/pyelftools-${version}.tar.gz")
build() {
cd pyelftools-${version}
find * -type f -name '*.py' -exec sed -i 's@^#!/usr/bin/env python$@\03@' {} +
python3 -m build --wheel --no-isolation
python3 test/run_all_unittests.py
python3 test/run_examples_test.py
python3 test/run_readelf_tests.py
python3 -m installer --destdir="${PKG}" dist/*.whl
install -Dm 644 LICENSE -t "${PKG}/usr/share/licenses/${name}"
install -Dm 644 README.rst CHANGES -t "${PKG}/usr/share/doc/${name}"
cp -r examples "${PKG}/usr/share/doc/${name}"
}
|