From b47bc76c28de49710b3b4b00b64158241e53bf4f Mon Sep 17 00:00:00 2001 From: xhaa123 Date: Mon, 14 Oct 2024 18:05:54 +0800 Subject: [PATCH] libcap 2.69-1 --- PKGBUILD | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 PKGBUILD diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..c8c65a6 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# This is an example PKGBUILD file. Use this as a start to creating your own, +# and remove these comments. For more information, see 'man PKGBUILD'. +# NOTE: Please fill out the license field for your package! If it is unknown, +# then please put 'unknown'. + +# Maintainer: Future Linux Team +pkgname=libcap +pkgver=2.69 +pkgrel=1 +pkgdesc="POSIX 1003.1e capabilities" +arch=('x86_64') +url="https://sites.google.com/site/fullycapable/" +license=('BSD-3-Clause OR GPL-2.0-only') +depends=('glibc' 'gcc-libs' 'linux-pam') +makedepends=('linux-api-headers') +source=(https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/${pkgname}-${pkgver}.tar.xz) +sha256sums=(f311f8f3dad84699d0566d1d6f7ec943a9298b28f714cae3c931dfd57492d7eb) + +prepare() { + cd ${pkgname}-${pkgver} + + sed -i '/install -m.*STA/d' libcap/Makefile +} + +build() { + cd ${pkgname}-${pkgver} + + + BUILD_CC=${CHOST}-gcc CC=${CHOST}-gcc make prefix=/usr lib=lib64 + BUILD_CC=${CHOST}-gcc CC=${CHOST}-gcc make -C pam_cap +} + +package() { + cd ${pkgname}-${pkgver} + + make prefix=${pkgdir}/usr lib=lib64 install + + install -vDm755 pam_cap/pam_cap.so ${pkgdir}/usr/lib64/securityi/pam_cap.so + install -vDm644 pam_cap/capability.conf ${pkgdir}/etc/security/capability.conf +}