aboutsummaryrefslogtreecommitdiffstats
path: root/community/py3-evtx
diff options
context:
space:
mode:
Diffstat (limited to 'community/py3-evtx')
-rw-r--r--community/py3-evtx/APKBUILD47
1 files changed, 47 insertions, 0 deletions
diff --git a/community/py3-evtx/APKBUILD b/community/py3-evtx/APKBUILD
new file mode 100644
index 0000000000..a405260820
--- /dev/null
+++ b/community/py3-evtx/APKBUILD
@@ -0,0 +1,47 @@
+# Contributor: Francesco Colista <fcolista@alpinelinux.org>
+# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
+pkgname=py-evtx
+_pkgname=python-evtx
+pkgver=0.6.1
+pkgrel=1
+pkgdesc="Pure Python parser for recent Windows Event Log files (.evtx)"
+url="http://www.williballenthin.com/evtx/index.html"
+arch="noarch"
+license="Apache-2.0"
+depends=""
+makedepends="python2-dev py-setuptools python3-dev"
+install=""
+subpackages="py3-${pkgname/py-/}:_py3 py2-${pkgname/py-/}:_py2"
+source="$pkgname-$pkgver.tar.gz::https://github.com/williballenthin/$_pkgname/archive/v$pkgver.tar.gz"
+builddir="$srcdir/$_pkgname-$pkgver"
+
+builddir="$srcdir"/$_pkgname-$pkgver
+
+build() {
+ cd "$builddir"
+ python2 setup.py build || return 1
+ python3 setup.py build || return 1
+}
+
+package() {
+ mkdir -p "$pkgdir"
+}
+
+_py() {
+ local python=$1
+ pkgdesc="$pkgdesc - $python"
+ install_if="$pkgname=$pkgver-r$pkgrel $python"
+ cd "$builddir"
+ $python setup.py install --prefix=/usr --root="$subpkgdir"
+}
+
+_py2() {
+ _py python2
+ replaces="$pkgname"
+}
+
+_py3() {
+ _py python3
+}
+
+sha512sums="e0b0a5a002b2aa82262b49b269ab84be8ee57f1de69daf5b3e9e5167915fa63b756da240856fc37cacbabf7910189d3b5270e0d18905d09a8fd1f44ec8b3d1e2 py-evtx-0.6.1.tar.gz"