void-packages/srcpkgs/audit/template

93 lines
2.5 KiB
Bash

# Template file for 'audit'
pkgname=audit
version=3.0.1
revision=1
build_style=gnu-configure
configure_args="--libdir=/usr/lib --enable-shared=audit --enable-gssapi-krb5
--with-apparmor --with-libcap-ng --with-python3"
hostmakedepends="automake libtool pkg-config intltool python3 swig"
makedepends="mit-krb5-devel libldap-devel libapparmor-devel libcap-ng-devel
python3-devel"
make_dirs="/var/log/audit 0700 root root"
short_desc="Linux Security Auditing Framework"
maintainer="Cameron Nemo <cnemo@tutanota.com>"
license="GPL-2.0-or-later, LGPL-2.0-or-later"
homepage="https://people.redhat.com/sgrubb/audit"
changelog="https://raw.githubusercontent.com/linux-audit/audit-userspace/master/ChangeLog"
distfiles="${homepage}/${pkgname}-${version}.tar.gz"
checksum=994c4250d8fd43f3087a3c2ce73461832e30f1e9b278bf5bb03c3e07091155a5
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" --disable-zos-remote" ;;
*) ;;
esac
post_install() {
vinstall rules/10-base-config.rules 644 etc/audit/rules.d
vmkdir usr/share/examples/audit/rules.d
vcopy "rules/*" usr/share/examples/audit/rules.d
rm -rf -- "${DESTDIR}/etc/rc.d"
rm -rf -- "${DESTDIR}/etc/sysconfig"
vsv auditd
vsv auditctl
}
libaudit-common_package() {
short_desc+=" - Library common files"
pkg_install() {
vmove etc/libaudit.conf
vmove usr/share/man/man5/libaudit.conf.5
}
}
libaudit_package() {
short_desc+=" - Library"
depends="libaudit-common-${version}_${revision}"
pkg_install() {
vmove "usr/lib/libaudit.so.*"
}
}
libaudit-devel_package() {
short_desc+=" - Library development files"
depends="libaudit-${version}_${revision}"
pkg_install() {
vmove usr/include/libaudit.h
vmove usr/lib/libaudit.a
vmove usr/lib/libaudit.so
vmove usr/lib/pkgconfig/audit.pc
vmove usr/share/aclocal/audit.m4
vmove "usr/share/man/man3/audit*"
vmove usr/share/man/man3/get_auditfail_action.3
vmove usr/share/man/man3/set_aumessage_mode.3
}
}
libauparse_package() {
short_desc+=" - Parsing Library"
pkg_install() {
vmove "usr/lib/libauparse.so.*"
}
}
libauparse-devel_package() {
short_desc+=" - Parsing Library development files"
depends="libauparse-${version}_${revision}"
pkg_install() {
vmove "usr/include/auparse*.h"
vmove usr/lib/libauparse.a
vmove usr/lib/libauparse.so
vmove usr/lib/pkgconfig/auparse.pc
vmove "usr/share/man/man3/auparse*"
vmove "usr/share/man/man3/ausearch*"
}
}
python3-audit_package() {
lib32disabled=yes
short_desc+=" - Python3 bindings"
pkg_install() {
vmove "usr/lib/python3*"
}
}