summaryrefslogtreecommitdiff
path: root/manualPorts/python3-pyelftools/Pkgfile
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2023-01-15 14:31:20 +0100
committerErich Eckner <git@eckner.net>2023-01-15 14:31:20 +0100
commit675d169439647b214f81806dc7a915e75c17a3cb (patch)
tree0dae152c7450956668d2966b1aa8aa56c756cef7 /manualPorts/python3-pyelftools/Pkgfile
parentca4676785b0ab346bb06e018e440dda8c11636af (diff)
downloadcrux-ports-675d169439647b214f81806dc7a915e75c17a3cb.tar.xz
python3-pyelftools new
Diffstat (limited to 'manualPorts/python3-pyelftools/Pkgfile')
-rw-r--r--manualPorts/python3-pyelftools/Pkgfile25
1 files changed, 25 insertions, 0 deletions
diff --git a/manualPorts/python3-pyelftools/Pkgfile b/manualPorts/python3-pyelftools/Pkgfile
new file mode 100644
index 0000000..a49836b
--- /dev/null
+++ b/manualPorts/python3-pyelftools/Pkgfile
@@ -0,0 +1,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}"
+
+}