# Maintainer: Nicolas Iooss (nicolas iooss m4x org) # Contributor: Timothée Ravier # Contributor: Nicky726 (Nicky726 gmail com) # Contributor: Sergej Pupykin (pupykin s+arch gmail com) pkgname=sepolgen pkgver=2.6 pkgrel=2 pkgdesc="SELinux policy generator" groups=('selinux') arch=('any') url='http://userspace.selinuxproject.org' license=('GPL') makedepends=('python2') depends=('python' 'libselinux') optdepends=('python2: python2 bindings') conflicts=("selinux-usr-${pkgname}") provides=("selinux-usr-${pkgname}=${pkgver}-${pkgrel}") source=("https://raw.githubusercontent.com/wiki/SELinuxProject/selinux/files/releases/20161014/${pkgname}-${pkgver}.tar.gz") sha256sums=('6a327b1576d914e57ad796a541a7a9bcceefb14c445355559993de0fdb8e7a60') build() { cd "${pkgname}-${pkgver}" make PYTHON=python2 make PYTHON=python3 } package(){ cd "${pkgname}-${pkgver}" make PYTHON=python2 DESTDIR="${pkgdir}" install make PYTHON=python3 DESTDIR="${pkgdir}" install python2 -m compileall "${pkgdir}/$(python2 -c 'import site; print(site.getsitepackages()[0])')" python3 -m compileall "${pkgdir}/$(python3 -c 'import site; print(site.getsitepackages()[0])')" }