[arch-commits] Commit in python-yara/repos (2 files)

Felix Yan felixonmars at gemini.archlinux.org
Wed Dec 1 14:57:17 UTC 2021


    Date: Wednesday, December 1, 2021 @ 14:57:17
  Author: felixonmars
Revision: 1059591

archrelease: copy trunk to community-staging-x86_64

Added:
  python-yara/repos/community-staging-x86_64/
  python-yara/repos/community-staging-x86_64/PKGBUILD
    (from rev 1059588, python-yara/trunk/PKGBUILD)

----------+
 PKGBUILD |   42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

Copied: python-yara/repos/community-staging-x86_64/PKGBUILD (from rev 1059588, python-yara/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2021-12-01 14:57:17 UTC (rev 1059591)
@@ -0,0 +1,42 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+# Contributor: arch3y <arch3y[at]archstrike[dot]org>
+
+_gitname=yara-python
+pkgname=python-yara
+pkgver=4.1.0
+_gitcommit=dc838e211e45442d219012099aaa63efa812c4be
+pkgrel=2
+pkgdesc='Tool aimed at helping malware researchers to identify and classify malware samples'
+url='https://github.com/VirusTotal/yara-python'
+arch=('x86_64')
+license=('Apache')
+depends=('python' 'yara' 'libyara.so' 'glibc')
+makedepends=('git' 'python-setuptools')
+source=(${pkgname}::git+"https://github.com/VirusTotal/${_gitname}#commit=${_gitcommit}")
+sha512sums=('SKIP')
+
+pkgver() {
+  cd ${pkgname}
+  git describe --tags --match 'v*' | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+  cd ${pkgname}
+  python setup.py build --dynamic-linking
+}
+
+check() {
+  cd ${pkgname}
+  local PYTHONVERSION="$(python -c 'import sys; print("{}.{}".format(sys.version_info.major, sys.version_info.minor))')"
+  PYTHONPATH="build/lib.linux-${CARCH}-${PYTHONVERSION}" \
+    python tests.py
+}
+
+package() {
+  cd ${pkgname}
+  python setup.py install --root="${pkgdir}" -O1 --skip-build
+  install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+  ln -s /usr/share/doc/yara/docs "${pkgdir}/usr/share/doc/${pkgname}/docs"
+}
+
+# vim: ts=2 sw=2 et:



More information about the arch-commits mailing list