summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-05-16 05:56:08 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2015-05-16 05:56:08 +0000
commit7ebbe75e04d64f942fdf4ec7f400a40b221d728b (patch)
tree990eb75ed008ca048e6942023bfb6ab1c60445cd /sys-process
parentactually drop old. (diff)
downloadhistorical-7ebbe75e04d64f942fdf4ec7f400a40b221d728b.tar.gz
historical-7ebbe75e04d64f942fdf4ec7f400a40b221d728b.tar.bz2
historical-7ebbe75e04d64f942fdf4ec7f400a40b221d728b.zip
Bug 448470: adjust preserved libs.
Package-Manager: portage-2.2.18/cvs/Linux x86_64
Diffstat (limited to 'sys-process')
-rw-r--r--sys-process/audit/ChangeLog9
-rw-r--r--sys-process/audit/Manifest25
-rw-r--r--sys-process/audit/audit-2.2.2-r3.ebuild195
-rw-r--r--sys-process/audit/audit-2.4.1-r1.ebuild187
4 files changed, 394 insertions, 22 deletions
diff --git a/sys-process/audit/ChangeLog b/sys-process/audit/ChangeLog
index 0085033b2b44..27dd427262c4 100644
--- a/sys-process/audit/ChangeLog
+++ b/sys-process/audit/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for sys-process/audit
# Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-process/audit/ChangeLog,v 1.105 2015/03/21 13:19:16 polynomial-c Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-process/audit/ChangeLog,v 1.106 2015/05/16 05:56:03 robbat2 Exp $
+
+*audit-2.2.2-r3 (16 May 2015)
+*audit-2.4.1-r1 (16 May 2015)
+
+ 16 May 2015; Robin H. Johnson <robbat2@gentoo.org> +audit-2.2.2-r3.ebuild,
+ +audit-2.4.1-r1.ebuild:
+ Bug 448470: adjust preserved libs.
*audit-2.4.1 (21 Mar 2015)
diff --git a/sys-process/audit/Manifest b/sys-process/audit/Manifest
index b6adb9339ce8..e22e098e8b03 100644
--- a/sys-process/audit/Manifest
+++ b/sys-process/audit/Manifest
@@ -1,6 +1,3 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA256
-
AUX audit-1.7.17-python.patch 448 SHA256 9d29b2c67484c64cbf2e940a084d5f4c2bcbaca85a78f5c697ea20cc7ed2cb87 SHA512 ed816ca60294109ff3ef825081a4042d592a1841a597ec5514ed6f6696331a3aeafc9147ca1f5648df65c2fedc32a966825d9444a1634388aa06cc320ab2542f WHIRLPOOL 685f661e79b2f6facd7d3a6c603a8c8c5ef5de7d37f4dcab310c23cddf239ca3a2fb3c0622cb308e32678c6f16ed34e81bf6b5a8e4b391e01bf69790bee97512
AUX audit-1.7.18-as-needed.patch 2346 SHA256 d83311d4b1e109712a32771943c7da72be939633d0fe0ba33c99a405fc6a0f14 SHA512 e30bb39c97d4fb92594b0dcc0b8160bbf5af7096ef261c1f5e2786d2ebe6f764806c9cf18dc2ab2156057cf8a12c259faa804c98d58a4a90ac3d1a081979567a WHIRLPOOL 508e582f9feaca11d5b74b12601961959d40f4dcd0dfe002a5af47f5e3b3cb4d79037ab67d715687cc946feb859e4a2453712f34055cf7a8cca75d47935d4baf
AUX audit-1.7.18-missing_headers.patch 381 SHA256 9bcd61e976bfb422f199b6553a1dfa745f99979fa2295b53fd8163b171d1e487 SHA512 c115ecd19f15b2b20fb233f6304ff112b85b96bbca32a8274e5215d8622be71e8ed997ca630e4a3dda3436475a0af565d51163348c09c0721d6c9ce7324e0288 WHIRLPOOL 7b138cf18929ddfaacd0e7cc256f565865076d7d68724292e6769bb7ac32a836ae315454c71f701049c300e06c582a4aa5deb4815be4c5dd2a07c053c1fd4c3d
@@ -25,23 +22,9 @@ EBUILD audit-1.7.18.ebuild 3491 SHA256 ef678f9bb88c2f1dd949cdf3bd92207b4d0f5bd29
EBUILD audit-2.0.5.ebuild 4468 SHA256 af5a547f8a131e00050baf000232da2d742029199356d76db195a68e850c1152 SHA512 99837c530ca5a5f35e241f4c3b70e4bfe45a74e91d2181356f417b3f0fc72a1fdf8172c7d52c5b7322a1d59cb351d6ce3d69e623778ca77005cd01e0c86cb7a4 WHIRLPOOL e9554be479f1b11c6d466a4c11b54aa6d39df4c6617934d70ffc410d6006b4b4a6ea980a316dde91cbdb4b91ebb1190c17825df14b04e104a583b57e0a3cc1d9
EBUILD audit-2.1.3-r1.ebuild 4974 SHA256 5fef4673e77a4a04837756ade173b97c42b18e6f4097736e67bd3d1cd1ebbd46 SHA512 b0669cd7fc48e360e71cc5049447eed028ae904bc6088008cf74b480c9783cbe98e6717f871ffbf470adb9ae9c61c4fda884316cec724729a9672da07a125994 WHIRLPOOL d8bab3e763e47a6dcc83f67fc95a7ed075bdacda98a448f2ae404e60cb2ad7fa0c72881053d11f5080c9f1fd7d55a27581b8870ecd06b5140bee51985c613a21
EBUILD audit-2.2.2-r2.ebuild 5283 SHA256 b1dc406f7661159c69927b733e88a480ce68253ee81ef014b0f674634c89ab51 SHA512 0d381a4c5a23cdef40d6f678904fb67b8ad66da83f1c116e62082d34cd533b2c079f1ca0eabd15883331d83e40ae7ce49081d0275b9152250d010b7d424d91d0 WHIRLPOOL 9de06f6596438091acbbbf8e39840554ba761e291203b73fedc4c7243d72048b1b5d30a922ffe9b5ac03171e1116bd2c5d55b5e7aced27cfa50813adacce97b7
+EBUILD audit-2.2.2-r3.ebuild 5279 SHA256 dbf9611825e39af7a71dbcf786fc9add6f7700e21fdd184143c0da133c1de0f8 SHA512 9ebb53b92b2653c0873a90861ccf4ba56cdc9f8a5c27d92f13afb1c1d4536d9d9947abf2690fa508c574fa492a513d2564bfc15ccf89ca3e14579cf0effe5e58 WHIRLPOOL 56f795d321cf7853b31a0cd6a322f0eea3ea37258bb3efa0e3eca1bb47208a924a09d57729d1363c326ff9a8c343a214ca755d400c064025b262b606cd495d43
+EBUILD audit-2.4.1-r1.ebuild 4945 SHA256 dbf87649b8d33199c3d4dc77df26a5466bf54e65e92d2b4fafc2f065a0bfbb2b SHA512 bb2a30339ebd8448138e31411aa8b8dd3fd7f6056cbf93af69feb99cf2a56ffa6bbd34b7ecfd2e98fe8248f6d8990f676eb122b672e0000b27756a2507688806 WHIRLPOOL 533e9cb7fc896bde9053bbd6c275c0aee303432e6e7a5908bb2b41364dc859446668b24bc5ca69e5e0a444a09e89e5b792a070ae46ae1347a860f21080b962c1
EBUILD audit-2.4.1.ebuild 4963 SHA256 97081357902a61c387e0707e709a184ed302586f4f948cb82c25e823a2b32372 SHA512 27a47385f5f9aa5ea224d03e3d9079e4d0f84fafdf45af6e8db68d2af95af2e145b134f6585ca7e4c1b38ff0e6f2a9c013be51cbf0b8281f029e70429937ccd3 WHIRLPOOL a554cedcf9797230ada2f0e90851b5a96ac8f9a3950faf4b2397cf275ee5e14bad098150c6d3d04dd348d68f7a41ae346705f91e9b58d5480fd4f380791d91e3
-MISC ChangeLog 16768 SHA256 98fc19b6d85b71cb855c83fac5d00f025a934de0bf48b71c90e072131ccfc81c SHA512 6e2a3244327144ae6b2bdcbdcc9b2484e2096ca352c675176e8f8d53fe001f966b21c5ba6db9c2efd88b8a71da77b39cc104d55f6384aa0558522baea65c8731 WHIRLPOOL 252b9173784049454c9d70ee01f20358eee383a85f52e16801b5c6332887078df7500a5956c1c3cf23fa13abc669568fe450b5aa548f4ab31a21417c44f03e2a
+MISC ChangeLog 16965 SHA256 24f0072f338ec8d120cc622dc5ab51aecce3748fce2e30ce7fe0c606ed641e25 SHA512 478aa9bcbe05566faf3b10846bb70e8e26e2719a4683b9863d6d36f292c86c77b03f84204aa8b5579565db83cf932d99c3c5174939db5d5b9589053e3044402e WHIRLPOOL bf429ab5ad1a667bbaec700c2ebacc16e7b1bac0e7b74abb9aec040ff3a2e5dc39e861f929d6c25dcdfd5c115a49e0a48fc21ba72e26d53e27f7cdce76cf27fa
+MISC audit-2.4.1-r1.ebuild.orig 4963 SHA256 97081357902a61c387e0707e709a184ed302586f4f948cb82c25e823a2b32372 SHA512 27a47385f5f9aa5ea224d03e3d9079e4d0f84fafdf45af6e8db68d2af95af2e145b134f6585ca7e4c1b38ff0e6f2a9c013be51cbf0b8281f029e70429937ccd3 WHIRLPOOL a554cedcf9797230ada2f0e90851b5a96ac8f9a3950faf4b2397cf275ee5e14bad098150c6d3d04dd348d68f7a41ae346705f91e9b58d5480fd4f380791d91e3
MISC metadata.xml 208 SHA256 474aad89b28273a47e9d612283399fab63cd9ada8b3c4fa65b16250128abf342 SHA512 761ae3cffc33d4832cd02525e53fa449295e779fac539a6c11d746001689e781939e059c8a444365b42b291e295d5d1620d67af401c2c80c568be8ef596d147d WHIRLPOOL 060c71b4ace40817c787afb38b4919804322e09983dba790fbdcf0c3021a7bfa94ed0f1f4fb5db8893d0c68aebdec378ed055f420501bd7df0f03eec50e220aa
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v2
-
-iQIcBAEBCAAGBQJVDW/VAAoJEPiazRVxLXTF6JwP/2qVpM2OOysNlHDpZebdJIPk
-NQIgo53Lj2+bQDdSUPuQqrUMrcvmH2ed5swZyAmIDaq/dAAqHFoIftsFF1zlf/iV
-2GP7VPmkINsEEV+qBv3wTsZVGNVUQyphJ0/H2lCrStbPduIvAIWalFfM52ESqXf1
-WdW2ezS3nYbes1gSPwwMaaEPmkIk0jMfwlF3AMZG8uQ4UEKp2Mlt6od6SX79NkX4
-7W+9Dl3Kxl7YeUpsxMXVLlTHA9KM422bA4ujoAMh2x1SJeA63oX6fK96q5xzorhK
-WAHrYnT2HYa4+7DcwVOCKceVdKaP1RqBMzESPzjA01lo7jW7or/JWastmL+cZeeW
-sJb9breTl8+0e+E4HzAH0aXVhrw2gVS/fFv6L84lVodChCnUJSepbWrSV+W70C04
-lQCeTVBZWRtY3UGXngc9DpYakCVGo7NV68Q93TpuT5u8J6R96MJ75Yxm+uZiar3o
-EI78Oh1X+fsFH4fU8jeRKOzqZ1h3hOrZT32FA1AfnlZ9cvGDPRuoYtOd62hkVin5
-DboDqrqGvCDhaUwydjmFLnI6JMZPRnRd5D4FJnApJZe5GESovx/ZebluWdfddVEm
-Zn+ImI8ucSknuZ38KGOzDXov4s2WDWCWmLjF9CtSvrzs1vk/E7CxIvJ4vgSLQn4D
-Uhb1tQNP+1ddxkZ25USg
-=/YC+
------END PGP SIGNATURE-----
diff --git a/sys-process/audit/audit-2.2.2-r3.ebuild b/sys-process/audit/audit-2.2.2-r3.ebuild
new file mode 100644
index 000000000000..b3f994a4e4c4
--- /dev/null
+++ b/sys-process/audit/audit-2.2.2-r3.ebuild
@@ -0,0 +1,195 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-process/audit/audit-2.2.2-r3.ebuild,v 1.1 2015/05/16 05:56:03 robbat2 Exp $
+
+EAPI="5"
+
+PYTHON_COMPAT=( python2_7 )
+
+inherit autotools multilib multilib-minimal toolchain-funcs python-r1 linux-info eutils systemd
+
+DESCRIPTION="Userspace utilities for storing and processing auditing records"
+HOMEPAGE="http://people.redhat.com/sgrubb/audit/"
+SRC_URI="http://people.redhat.com/sgrubb/audit/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="ldap prelude python"
+# Testcases are pretty useless as they are built for RedHat users/groups and
+# kernels.
+RESTRICT="test"
+
+RDEPEND="ldap? ( net-nds/openldap )
+ prelude? ( dev-libs/libprelude )
+ sys-libs/libcap-ng"
+DEPEND="${RDEPEND}
+ python? ( dev-lang/swig )
+ >=sys-kernel/linux-headers-2.6.34"
+# Do not use os-headers as this is linux specific
+
+CONFIG_CHECK="~AUDIT"
+
+pkg_setup() {
+ linux-info_pkg_setup
+}
+
+src_prepare() {
+ # Old patch applies fine
+ #EPATCH_OPTS="-p0 -d${S}" epatch "${FILESDIR}"/${PN}-1.5.4-build.patch
+
+ # Applied by upstream
+ #EPATCH_OPTS="-p1 -d${S}" epatch "${FILESDIR}"/${PN}-1.5.4-swig-gcc-attribute.patch
+
+ # Do not build GUI tools
+ sed -i \
+ -e '/AC_CONFIG_SUBDIRS.*system-config-audit/d' \
+ "${S}"/configure.ac || die
+ sed -i \
+ -e 's,system-config-audit,,g' \
+ "${S}"/Makefile.am || die
+ rm -rf "${S}"/system-config-audit
+
+ # Probably goes away in 1.6.9
+ #EPATCH_OPTS="-p1 -d${S}" epatch "${FILESDIR}"/audit-1.6.8-subdirs-fix.patch
+
+ if ! use ldap; then
+ sed -i \
+ -e '/^AC_OUTPUT/s,audisp/plugins/zos-remote/Makefile,,g' \
+ "${S}"/configure.ac || die
+ sed -i \
+ -e '/^SUBDIRS/s,zos-remote,,g' \
+ "${S}"/audisp/plugins/Makefile.am || die
+ fi
+
+ # Don't build static version of Python module.
+ epatch "${FILESDIR}"/${PN}-2.1.3-python.patch
+
+ # glibc/kernel upstreams suck with both defining ia64_fpreg
+ # This patch is a horribly workaround that is only valid as long as you
+ # don't need the OTHER definitions in fpu.h.
+ epatch "${FILESDIR}"/${PN}-2.1.3-ia64-compile-fix.patch
+
+ # Python bindings are built/installed manually.
+ sed -e "/^SUBDIRS =/s/ python//" -i bindings/Makefile.am
+ sed -e "/^SUBDIRS .*=/s/ swig//" -i Makefile.am
+
+ # Regenerate autotooling
+ eautoreconf
+
+ # Bug 352198: Avoid parallel build fail
+ cd "${S}"/src/mt
+ [[ ! -s private.h ]] && ln -s ../../lib/private.h .
+}
+
+multilib_src_configure() {
+ local ECONF_SOURCE=${S}
+ #append-flags -D'__attribute__(x)='
+ econf \
+ --sbindir=/sbin \
+ --enable-systemd \
+ --without-python \
+ $(multilib_native_use_with prelude)
+
+ if multilib_is_native_abi; then
+ python_configure() {
+ mkdir -p "${BUILD_DIR}" || die
+ cd "${BUILD_DIR}" || die
+ econf --with-python
+ }
+
+ use python && python_foreach_impl python_configure
+ fi
+}
+
+multilib_src_compile() {
+ if multilib_is_native_abi; then
+ default
+
+ python_compile() {
+ emake -C "${BUILD_DIR}"/swig \
+ VPATH="${native_build}/lib" \
+ LIBS="${native_build}/lib/libaudit.la"
+ emake -C "${BUILD_DIR}"/bindings/python \
+ VPATH="${S}/bindings/python:${native_build}/bindings/python" \
+ auparse_la_LIBADD="${native_build}/auparse/libauparse.la ${native_build}/lib/libaudit.la"
+ }
+
+ local native_build=${BUILD_DIR}
+ use python && python_foreach_impl python_compile
+ else
+ emake -C lib
+ emake -C auparse
+ fi
+}
+
+multilib_src_install() {
+ if multilib_is_native_abi; then
+ emake DESTDIR="${D}" initdir="$(systemd_get_unitdir)" install
+
+ python_install() {
+ emake -C "${BUILD_DIR}"/swig \
+ VPATH="${native_build}/lib" \
+ DESTDIR="${D}" install
+ emake -C "${BUILD_DIR}"/bindings/python \
+ VPATH="${S}/bindings/python:${native_build}/bindings/python" \
+ DESTDIR="${D}" install
+ }
+
+ local native_build=${BUILD_DIR}
+ use python && python_foreach_impl python_install
+
+ # things like shadow use this so we need to be in /
+ gen_usr_ldscript -a audit auparse
+ else
+ emake -C lib DESTDIR="${D}" install
+ emake -C auparse DESTDIR="${D}" install
+ fi
+}
+
+multilib_src_install_all() {
+ dodoc AUTHORS ChangeLog README* THANKS TODO
+ docinto contrib
+ dodoc contrib/{*.rules,avc_snap,skeleton.c}
+ docinto contrib/plugin
+ dodoc contrib/plugin/*
+
+ newinitd "${FILESDIR}"/auditd-init.d-2.1.3 auditd
+ newconfd "${FILESDIR}"/auditd-conf.d-2.1.3 auditd
+
+ [ -f "${D}"/sbin/audisp-remote ] && \
+ dodir /usr/sbin && \
+ mv "${D}"/{sbin,usr/sbin}/audisp-remote || die
+
+ # Gentoo rules
+ insinto /etc/audit/
+ newins "${FILESDIR}"/audit.rules-2.1.3 audit.rules
+ doins "${FILESDIR}"/audit.rules.stop*
+
+ # audit logs go here
+ keepdir /var/log/audit/
+
+ # Security
+ lockdown_perms "${D}"
+
+ prune_libtool_files --modules
+}
+
+pkg_preinst() {
+ # Preserve from the audit-1 series
+ preserve_old_lib /$(get_libdir)/libaudit.so.0
+}
+
+pkg_postinst() {
+ lockdown_perms "${ROOT}"
+ # Preserve from the audit-1 series
+ preserve_old_lib_notify /$(get_libdir)/libaudit.so.0
+}
+
+lockdown_perms() {
+ # upstream wants these to have restrictive perms
+ basedir="$1"
+ chmod 0750 "${basedir}"/sbin/au{ditctl,report,dispd,ditd,search,trace} 2>/dev/null
+ chmod 0750 "${basedir}"/var/log/audit/ 2>/dev/null
+ chmod 0640 "${basedir}"/etc/{audit/,}{auditd.conf,audit.rules*} 2>/dev/null
+}
diff --git a/sys-process/audit/audit-2.4.1-r1.ebuild b/sys-process/audit/audit-2.4.1-r1.ebuild
new file mode 100644
index 000000000000..cf06ee81bfbb
--- /dev/null
+++ b/sys-process/audit/audit-2.4.1-r1.ebuild
@@ -0,0 +1,187 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-process/audit/audit-2.4.1-r1.ebuild,v 1.1 2015/05/16 05:56:03 robbat2 Exp $
+
+EAPI="5"
+
+PYTHON_COMPAT=( python2_7 )
+
+inherit autotools multilib multilib-minimal toolchain-funcs python-r1 linux-info eutils systemd
+
+DESCRIPTION="Userspace utilities for storing and processing auditing records"
+HOMEPAGE="http://people.redhat.com/sgrubb/audit/"
+SRC_URI="http://people.redhat.com/sgrubb/audit/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="ldap python"
+# Testcases are pretty useless as they are built for RedHat users/groups and
+# kernels.
+RESTRICT="test"
+
+RDEPEND="ldap? ( net-nds/openldap )
+ sys-libs/libcap-ng"
+DEPEND="${RDEPEND}
+ python? ( ${PYTHON_DEPS}
+ dev-lang/swig )
+ >=sys-kernel/linux-headers-2.6.34"
+# Do not use os-headers as this is linux specific
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+CONFIG_CHECK="~AUDIT"
+
+pkg_setup() {
+ linux-info_pkg_setup
+}
+
+src_prepare() {
+ # Do not build GUI tools
+ sed -i \
+ -e '/AC_CONFIG_SUBDIRS.*system-config-audit/d' \
+ "${S}"/configure.ac || die
+ sed -i \
+ -e 's,system-config-audit,,g' \
+ "${S}"/Makefile.am || die
+ rm -rf "${S}"/system-config-audit
+
+ if ! use ldap; then
+ sed -i \
+ -e '/^AC_OUTPUT/s,audisp/plugins/zos-remote/Makefile,,g' \
+ "${S}"/configure.ac || die
+ sed -i \
+ -e '/^SUBDIRS/s,zos-remote,,g' \
+ "${S}"/audisp/plugins/Makefile.am || die
+ fi
+
+ # Don't build static version of Python module.
+ epatch "${FILESDIR}"/${PN}-2.4.1-python.patch
+
+ # glibc/kernel upstreams suck with both defining ia64_fpreg
+ # This patch is a horribly workaround that is only valid as long as you
+ # don't need the OTHER definitions in fpu.h.
+ epatch "${FILESDIR}"/${PN}-2.1.3-ia64-compile-fix.patch
+
+ # Python bindings are built/installed manually.
+ sed -e "/^SUBDIRS =/s/ python//" -i bindings/Makefile.am
+ sed -e "/^SUBDIRS .*=/s/ swig//" -i Makefile.am
+
+ # Regenerate autotooling
+ eautoreconf
+
+ # Bug 352198: Avoid parallel build fail
+ cd "${S}"/src/mt
+ [[ ! -s private.h ]] && ln -s ../../lib/private.h .
+}
+
+multilib_src_configure() {
+ local ECONF_SOURCE=${S}
+ #append-flags -D'__attribute__(x)='
+ econf \
+ --sbindir=/sbin \
+ --enable-systemd \
+ --without-python
+
+ if multilib_is_native_abi; then
+ python_configure() {
+ mkdir -p "${BUILD_DIR}" || die
+ cd "${BUILD_DIR}" || die
+ econf --with-python
+ }
+
+ use python && python_foreach_impl python_configure
+ fi
+}
+
+multilib_src_compile() {
+ if multilib_is_native_abi; then
+ default
+
+ python_compile() {
+ emake -C "${BUILD_DIR}"/swig \
+ VPATH="${native_build}/lib" \
+ LIBS="${native_build}/lib/libaudit.la"
+ emake -C "${BUILD_DIR}"/bindings/python \
+ VPATH="${S}/bindings/python:${native_build}/bindings/python" \
+ auparse_la_LIBADD="${native_build}/auparse/libauparse.la ${native_build}/lib/libaudit.la"
+ }
+
+ local native_build=${BUILD_DIR}
+ use python && python_foreach_impl python_compile
+ else
+ emake -C lib
+ emake -C auparse
+ fi
+}
+
+multilib_src_install() {
+ if multilib_is_native_abi; then
+ emake DESTDIR="${D}" initdir="$(systemd_get_unitdir)" install
+
+ python_install() {
+ emake -C "${BUILD_DIR}"/swig \
+ VPATH="${native_build}/lib" \
+ DESTDIR="${D}" install
+ emake -C "${BUILD_DIR}"/bindings/python \
+ VPATH="${S}/bindings/python:${native_build}/bindings/python" \
+ DESTDIR="${D}" install
+ }
+
+ local native_build=${BUILD_DIR}
+ use python && python_foreach_impl python_install
+
+ # things like shadow use this so we need to be in /
+ gen_usr_ldscript -a audit auparse
+ else
+ emake -C lib DESTDIR="${D}" install
+ emake -C auparse DESTDIR="${D}" install
+ fi
+}
+
+multilib_src_install_all() {
+ dodoc AUTHORS ChangeLog README* THANKS TODO
+ docinto contrib
+ dodoc contrib/{*.rules,avc_snap,skeleton.c}
+ docinto contrib/plugin
+ dodoc contrib/plugin/*
+
+ newinitd "${FILESDIR}"/auditd-init.d-2.1.3 auditd
+ newconfd "${FILESDIR}"/auditd-conf.d-2.1.3 auditd
+
+ [ -f "${D}"/sbin/audisp-remote ] && \
+ dodir /usr/sbin && \
+ mv "${D}"/{sbin,usr/sbin}/audisp-remote || die
+
+ # Gentoo rules
+ insinto /etc/audit/
+ newins "${FILESDIR}"/audit.rules-2.1.3 audit.rules
+ doins "${FILESDIR}"/audit.rules.stop*
+
+ # audit logs go here
+ keepdir /var/log/audit/
+
+ # Security
+ lockdown_perms "${D}"
+
+ prune_libtool_files --modules
+}
+
+pkg_preinst() {
+ # Preserve from the audit-1 series
+ preserve_old_lib /$(get_libdir)/libaudit.so.0
+}
+
+pkg_postinst() {
+ lockdown_perms "${ROOT}"
+ # Preserve from the audit-1 series
+ preserve_old_lib_notify /$(get_libdir)/libaudit.so.0
+}
+
+lockdown_perms() {
+ # upstream wants these to have restrictive perms
+ basedir="$1"
+ chmod 0750 "${basedir}"/sbin/au{ditctl,report,dispd,ditd,search,trace} 2>/dev/null
+ chmod 0750 "${basedir}"/var/log/audit/ 2>/dev/null
+ chmod 0640 "${basedir}"/etc/{audit/,}{auditd.conf,audit.rules*} 2>/dev/null
+}