sys-process/criu: version bump to 3.7

Package-Manager: Portage-2.3.24, Repoman-2.3.6
This commit is contained in:
Matthias Maier
2018-02-11 21:01:42 -06:00
parent a57c229ec7
commit f4156bb8f8
2 changed files with 116 additions and 0 deletions

View File

@@ -1,2 +1,3 @@
DIST criu-2.5.tar.bz2 605226 BLAKE2B c4086b9822b119a648bda4f6cc831eba5b7e3fba5af41f8f0b1c00dac7d4aff88a71e81569c4559fd98113e76eba0653c67684f443c1c803c453209367a4c875 SHA512 ccf942005ff3b2a567726ddb8aa44048c130f1adf6e2cbdf48e919043c84a4e1c03ad0ec34b44263e5764bea62807a2cc0fa1135b929ad3166fb9486c2880570
DIST criu-3.6.tar.bz2 739437 BLAKE2B 0f128cf69a5a073df3abc736e3081b7d266573575c038a457fdf8adcdab668d957559f3b9a16606ff31871c3bf5e111349995c496c4236b5191340486814981f SHA512 5849024ac4660a5537ed37b6d98adf61d3f071e2a181d873a1f7ca6c4d00a4258445b4bc840e908d907bc34daf8a818450f54e6cdf4826a679e756c0cbc5d586
DIST criu-3.7.tar.bz2 749499 BLAKE2B 41222983183910b8a039a69e1a425993703e4f461c1cc0e64e92f877aff571d56c7f32cdae7848ef1633a15cac9e7b746f8c84a71f3607f7fc22959964820258 SHA512 8feb9e2579c04b67a7fe9631bb662504a7eb78550c3951cbe29252d87d9258fd6994533f6e60b0017b6a6e21bbdd5e7cd7e8a255be53b77b57efacec4e50140f

View File

@@ -0,0 +1,115 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 )
inherit eutils toolchain-funcs linux-info flag-o-matic python-r1 python-utils-r1
DESCRIPTION="utility to checkpoint/restore a process tree"
HOMEPAGE="http://criu.org/"
SRC_URI="http://download.openvz.org/criu/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64"
IUSE="python selinux setproctitle static-libs"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
RDEPEND="
dev-libs/protobuf-c
dev-libs/libnl:3
net-libs/libnet:1.1
sys-libs/libcap
python? ( ${PYTHON_DEPS} )
selinux? ( sys-libs/libselinux )
setproctitle? ( dev-libs/libbsd )"
DEPEND="${RDEPEND}
app-text/asciidoc
app-text/xmlto"
RDEPEND="${RDEPEND}
python? (
|| (
dev-python/protobuf-python[${PYTHON_USEDEP}]
dev-libs/protobuf[python,${PYTHON_USEDEP}]
)
dev-python/ipaddr[${PYTHON_USEDEP}]
)"
CONFIG_CHECK="~CHECKPOINT_RESTORE ~NAMESPACES ~PID_NS ~FHANDLE ~EVENTFD ~EPOLL ~INOTIFY_USER
~IA32_EMULATION ~UNIX_DIAG ~INET_DIAG ~INET_UDP_DIAG ~PACKET_DIAG ~NETLINK_DIAG"
RESTRICT="test"
PATCHES=(
"${FILESDIR}"/2.2/${PN}-2.2-flags.patch
"${FILESDIR}"/2.3/${PN}-2.3-no-git.patch
"${FILESDIR}"/${PN}-2.8-automagic-libbsd.patch
"${FILESDIR}"/2.0/${PN}-2.0-sysroot.patch
)
criu_arch() {
# criu infers the arch from $(uname -m). We never want this to happen.
case ${ARCH} in
amd64) echo "x86";;
arm64) echo "aarch64";;
*) echo "${ARCH}";;
esac
}
src_prepare() {
default
if ! use selinux; then
sed \
-e 's:libselinux:no_libselinux:g' \
-i Makefile.config || die
fi
}
src_compile() {
RAW_LDFLAGS="$(raw-ldflags)" emake \
CC="$(tc-getCC)" \
LD="$(tc-getLD)" \
OBJCOPY="$(tc-getOBJCOPY)" \
LIBDIR="${EPREFIX}/usr/$(get_libdir)" \
ARCH="$(criu_arch)" \
V=1 WERROR=0 DEBUG=0 \
SETPROCTITLE=$(usex setproctitle) \
PYCRIU=$(usex python) \
all docs
}
src_test() {
# root privileges are required to dump all necessary info
if [[ ${EUID} -eq 0 ]] ; then
emake -j1 CC="$(tc-getCC)" ARCH="$(criu_arch)" V=1 WERROR=0 test
fi
}
install_crit() {
"${PYTHON:-python}" ../scripts/crit-setup.py install --root="${D}" --prefix="${EPREFIX}/usr/"
}
src_install() {
emake \
ARCH="$(criu_arch)" \
PREFIX="${EPREFIX}"/usr \
LOGROTATEDIR="${EPREFIX}"/etc/logrotate.d \
DESTDIR="${D}" \
LIBDIR="${EPREFIX}/usr/$(get_libdir)" \
install
dodoc CREDITS README.md
if use python ; then
cd lib
python_foreach_impl install_crit
fi
if ! use static-libs; then
find "${D}" -name "*.a" -delete || die
fi
}