diff options
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 44 |
2 files changed, 64 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..657060120760 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = libselinux + pkgdesc = SELinux library and simple utilities + pkgver = 2.2 + pkgrel = 1 + url = http://userspace.selinuxproject.org + arch = i686 + arch = x86_64 + groups = selinux + license = GPL + depends = libsepol>=2.2 + depends = python2 + depends = python + depends = swig + depends = ruby + options = !emptydirs + source = http://userspace.selinuxproject.org/releases/20131030/libselinux-2.2.tar.gz + sha256sums = e9dc64216543a7283d786f623ac28e8867f8794138e7deba474a3aa8d02dce33 + +pkgname = libselinux + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..9955c474b1a9 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,44 @@ +# Maintainer: Timothée Ravier <tim@siosm.fr> +# Contributor: Nicky726 (Nicky726 <at> gmail <dot> com) +# Contributor: Sergej Pupykin (pupykin <dot> s+arch <at> gmail <dot> com) + +pkgname=libselinux +pkgver=2.2 +pkgrel=1 +pkgdesc="SELinux library and simple utilities" +arch=('i686' 'x86_64') +url='http://userspace.selinuxproject.org' +license=('GPL') +groups=('selinux') +depends=('libsepol>=2.2' 'python2' 'python' 'swig' 'ruby') +options=(!emptydirs) +source=("http://userspace.selinuxproject.org/releases/20131030/${pkgname}-${pkgver}.tar.gz") +sha256sums=('e9dc64216543a7283d786f623ac28e8867f8794138e7deba474a3aa8d02dce33') + +prepare() { + cd ${pkgname}-${pkgver} + sed -i 's|pkg-config --cflags ruby|pkg-config --cflags ruby-2.0|' src/Makefile + sed -i 's|site_ruby|vendor_ruby|' src/Makefile +} + +build() { + cd ${pkgname}-${pkgver} + make swigify + make all + make PYTHON=python2 pywrap + make PYTHON=python3 pywrap + make rubywrap +} + +package(){ + cd ${pkgname}-${pkgver} + make DESTDIR="${pkgdir}" LIBDIR="${pkgdir}"/usr/lib SHLIBDIR="${pkgdir}"/usr/lib install + make DESTDIR="${pkgdir}" LIBDIR="${pkgdir}"/usr/lib SHLIBDIR="${pkgdir}"/usr/lib PYTHON=python2 install-pywrap + make DESTDIR="${pkgdir}" LIBDIR="${pkgdir}"/usr/lib SHLIBDIR="${pkgdir}"/usr/lib PYTHON=python3 install-pywrap + make DESTDIR="${pkgdir}" LIBDIR="${pkgdir}"/usr/lib SHLIBDIR="${pkgdir}"/usr/lib install-rubywrap + + # /usr/lib/libselinux.so fix + cd "${pkgdir}"/usr/lib + rm libselinux.so + ln -s libselinux.so.1 libselinux.so +} |