* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2022-04-14 11:51 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2022-04-14 11:51 UTC (permalink / raw
To: gentoo-commits
commit: ff94e87fa07cb7c93bde70e2676aeec510a78e7d
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 14 11:48:25 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu Apr 14 11:51:22 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ff94e87f
app-containers/lxc: drop 4.0.11_p1-r1
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
app-containers/lxc/Manifest | 2 -
.../lxc/files/lxc-4.0.11_p1-liburing-sync1.patch | 29 ----
.../lxc/files/lxc-4.0.11_p1-liburing-sync2.patch | 28 ---
app-containers/lxc/lxc-4.0.11_p1-r1.ebuild | 188 ---------------------
4 files changed, 247 deletions(-)
diff --git a/app-containers/lxc/Manifest b/app-containers/lxc/Manifest
index e1145caad041..c736c09fa249 100644
--- a/app-containers/lxc/Manifest
+++ b/app-containers/lxc/Manifest
@@ -1,4 +1,2 @@
-DIST lxc-4.0.11.tar.gz 1543031 BLAKE2B 0309bbb96938e60e4cbe145fa0cc3c0a85d9154282a889d74167128b6166a280bb4d53df266990a529a98935ef2c12e8d2214e9a8f6cb293d47aa5808ebad82f SHA512 23287e468da8939334f4261bfcbb52eadcbe5806bd97896db38c84eb42f32143dc17bb8b9bb7f7f88584b72056553c9edc33ddb693a345ecf88f3177573fa9c0
-DIST lxc-4.0.11.tar.gz.asc 833 BLAKE2B 68804d1d5ad09e388541b3a95a98ca14202c513ea3544a7389a49f4e13ecffc17715bb023675134fd99047c727cffe09cbd0a89883054b82650ebd23366823a7 SHA512 49a54aaf018772db40e1dadc0a10e7d727a2b14b34c0a3c704fd3f7a12e60082abf4628cc0a489ee620ef2210c7542abbdb6d1432e4297ceef52cdd6b158a5f8
DIST lxc-4.0.12.tar.gz 1565070 BLAKE2B 819b5140b641dbc1ed6cf5f2840bb0ee6d3ab8c687f4f8064e42d347113bdf50fcbb653a6fb26598db0daab0c83ad88fe0d27fd2842fac9d7f5fef73656d7976 SHA512 04437d9c891cd3a22f756c42f05e97398772587175d65aff9d394f0f3e810efc5c1fe7077c39573de3ec259e0605bc2a7ea51093613b2cef908372ae338df19d
DIST lxc-4.0.12.tar.gz.asc 833 BLAKE2B 2fca60b5ac267a893f70875ccdbe39db6b98b5fe51fe396692449e310b6e680e7b142380e193f5d8299f18e796ed2fd0e08cd186859069877fcca6bc26e44717 SHA512 4f2912879e6f3bf5fdbebb902cf16ca6b766b5720b817c4b4996e62098a1d282327d330ffd9768d45d69aeddb50184dc8485b0ef75b046449ce4c544cdc43c9b
diff --git a/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync1.patch b/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync1.patch
deleted file mode 100644
index cd497a755523..000000000000
--- a/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync1.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From aac3f106ff012e1d6835b20c250dcf09c364530c Mon Sep 17 00:00:00 2001
-From: Christian Brauner <christian.brauner@ubuntu.com>
-Date: Thu, 28 Oct 2021 17:39:11 +0200
-Subject: [PATCH] mainloop: make sure that descr->ring is allocated
-
-This is future proofing more than anything else.
-
-Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
----
- src/lxc/mainloop.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/src/lxc/mainloop.c b/src/lxc/mainloop.c
-index 7c8f5d86af..17a4d55293 100644
---- a/src/lxc/mainloop.c
-+++ b/src/lxc/mainloop.c
-@@ -515,8 +515,10 @@ void lxc_mainloop_close(struct lxc_async_descr *descr)
-
- if (descr->type == LXC_MAINLOOP_IO_URING) {
- #if HAVE_LIBURING
-- io_uring_queue_exit(descr->ring);
-- munmap(descr->ring, sizeof(struct io_uring));
-+ if (descr->ring) {
-+ io_uring_queue_exit(descr->ring);
-+ munmap(descr->ring, sizeof(struct io_uring));
-+ }
- #else
- ERROR("Unsupported io_uring mainloop");
- #endif
diff --git a/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync2.patch b/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync2.patch
deleted file mode 100644
index 33b8554193d3..000000000000
--- a/app-containers/lxc/files/lxc-4.0.11_p1-liburing-sync2.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From a585382b972c25ee8489147d94918d001ef439a7 Mon Sep 17 00:00:00 2001
-From: Christian Brauner <christian.brauner@ubuntu.com>
-Date: Thu, 28 Oct 2021 17:39:42 +0200
-Subject: [PATCH] start: check event loop type before closing fd
-
-Since this is a union we might otherwise stomp on io_uring mmap()ed
-memory.
-
-Fixes: #4016
-Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
----
- src/lxc/start.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/lxc/start.c b/src/lxc/start.c
-index 8f7173ec8c..1a6046c7a4 100644
---- a/src/lxc/start.c
-+++ b/src/lxc/start.c
-@@ -629,7 +629,8 @@ int lxc_poll(const char *name, struct lxc_handler *handler)
- TRACE("Mainloop is ready");
-
- ret = lxc_mainloop(&descr, -1);
-- close_prot_errno_disarm(descr.epfd);
-+ if (descr.type == LXC_MAINLOOP_EPOLL)
-+ close_prot_errno_disarm(descr.epfd);
- if (ret < 0 || !handler->init_died)
- goto out_mainloop_console;
-
diff --git a/app-containers/lxc/lxc-4.0.11_p1-r1.ebuild b/app-containers/lxc/lxc-4.0.11_p1-r1.ebuild
deleted file mode 100644
index 4e14a39d94fa..000000000000
--- a/app-containers/lxc/lxc-4.0.11_p1-r1.ebuild
+++ /dev/null
@@ -1,188 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools bash-completion-r1 linux-info flag-o-matic optfeature pam readme.gentoo-r1 systemd verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P/_p1}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P/_p1}.tar.gz.asc )"
-
-KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0"
-IUSE="apparmor +caps doc io-uring man pam seccomp selinux +ssl +tools verify-sig"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- app-misc/pax-utils
- sys-apps/util-linux
- sys-libs/libcap
- virtual/awk
- caps? ( sys-libs/libcap )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? (
- dev-libs/openssl:0=
- )"
-DEPEND="${RDEPEND}
- >=sys-kernel/linux-headers-4
- apparmor? ( sys-apps/apparmor )"
-BDEPEND="virtual/pkgconfig
- doc? ( app-doc/doxygen[dot] )
- man? ( app-text/docbook-sgml-utils )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch # bug 558854
- "${FILESDIR}"/${P}-liburing-sync1.patch #820545
- "${FILESDIR}"/${P}-liburing-sync2.patch #820545
-)
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-S="${WORKDIR}/${PN}-${PV/_p1}"
-
-src_prepare() {
- default
-
- export bashcompdir="/etc/bash_completion.d"
- eautoreconf
-}
-
-src_configure() {
- append-flags -fno-strict-aliasing
-
- local myeconfargs=(
- --bindir=/usr/bin
- --localstatedir=/var
- --sbindir=/usr/bin
-
- --with-config-path=/var/lib/lxc
- --with-distro=gentoo
- --with-init-script=systemd
- --with-rootfs-path=/var/lib/lxc/rootfs
- --with-runtime-path=/run
- --with-systemdsystemunitdir=$(systemd_get_systemunitdir)
-
- --disable-coverity-build
- --disable-dlog
- --disable-fuzzers
- --disable-mutex-debugging
- --disable-no-undefined
- --disable-rpath
- --disable-sanitizers
- --disable-tests
- --disable-werror
-
- --enable-bash
- --enable-commands
- --enable-memfd-rexec
- --enable-thread-safety
-
- $(use_enable apparmor)
- $(use_enable caps capabilities)
- $(use_enable doc api-docs)
- $(use_enable doc examples)
- $(use_enable io-uring liburing)
- $(use_enable man doc)
- $(use_enable pam)
- $(use_enable seccomp)
- $(use_enable selinux)
- $(use_enable ssl openssl)
- $(use_enable tools)
-
- $(use_with pam pamdir $(getpam_mod_dir))
- )
-
- econf "${myeconfargs[@]}"
-}
-
-src_install() {
- default
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
- mv "${ED}"/etc/bash_completion.d/lxc "${ED}"/$(get_bashcompdir)/lxc-start || die "Failed to relocate lxc bash-completion file."
- rm -r "${ED}"/etc/bash_completion.d || die "Failed to remove wrong bash_completion.d content."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,stop,unfreeze,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc
- rmdir "${D}"/var/cache/lxc "${D}"/var/cache || die "rmdir failed"
-
- find "${D}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Gentoo-specific additions!
- newinitd "${FILESDIR}/lxc.initd.8" lxc
-
- # Remember to compare our systemd unit file with the upstream one
- # config/init/systemd/lxc.service.in
- systemd_newunit "${FILESDIR}"/lxc_at.service.4.0.0 "lxc@.service"
-
- DOC_CONTENTS="
- For openrc, there is an init script provided with the package.
- You should only need to symlink /etc/init.d/lxc to
- /etc/init.d/lxc.configname to start the container defined in
- /etc/lxc/configname.conf.
-
- Correspondingly, for systemd a service file lxc@.service is installed.
- Enable and start lxc@configname in order to start the container defined
- in /etc/lxc/configname.conf."
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- readme.gentoo_print_elog
-
- elog "Please run 'lxc-checkconfig' to see optional kernel features."
- elog
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2022-08-16 7:55 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2022-08-16 7:55 UTC (permalink / raw
To: gentoo-commits
commit: ba5d9ca21d9fbceeeda1693e79fdffc2c2cb8286
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Tue Aug 16 07:51:44 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Aug 16 07:55:02 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ba5d9ca2
app-containers/lxc: drop 5.0.0, 5.0.0-r1
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
app-containers/lxc/Manifest | 2 -
.../lxc-5.0.0-dont-depend-on-static-libcap.patch | 27 ----
.../lxc-5.0.0-fix-strerror-r-char-p-musl.patch | 36 -----
app-containers/lxc/lxc-5.0.0-r1.ebuild | 160 ---------------------
app-containers/lxc/lxc-5.0.0.ebuild | 160 ---------------------
5 files changed, 385 deletions(-)
diff --git a/app-containers/lxc/Manifest b/app-containers/lxc/Manifest
index 6462391f1a33..0c60e874b27b 100644
--- a/app-containers/lxc/Manifest
+++ b/app-containers/lxc/Manifest
@@ -1,6 +1,4 @@
DIST lxc-4.0.12.tar.gz 1565070 BLAKE2B 819b5140b641dbc1ed6cf5f2840bb0ee6d3ab8c687f4f8064e42d347113bdf50fcbb653a6fb26598db0daab0c83ad88fe0d27fd2842fac9d7f5fef73656d7976 SHA512 04437d9c891cd3a22f756c42f05e97398772587175d65aff9d394f0f3e810efc5c1fe7077c39573de3ec259e0605bc2a7ea51093613b2cef908372ae338df19d
DIST lxc-4.0.12.tar.gz.asc 833 BLAKE2B 2fca60b5ac267a893f70875ccdbe39db6b98b5fe51fe396692449e310b6e680e7b142380e193f5d8299f18e796ed2fd0e08cd186859069877fcca6bc26e44717 SHA512 4f2912879e6f3bf5fdbebb902cf16ca6b766b5720b817c4b4996e62098a1d282327d330ffd9768d45d69aeddb50184dc8485b0ef75b046449ce4c544cdc43c9b
-DIST lxc-5.0.0.tar.gz 968678 BLAKE2B 82fa15353bdd78a1cc4cdb915f4a8366790b4ac317247bb03ceae91137368ef953ec52f6882ba9d44f6b9bddd3ac20579339e6bbedb4e5642adc81473825a91d SHA512 ecdce46a83602197716c9a4e50e0514a7e0764fbf34db6d5e3497e90669b4c8ced4b787fb220967d95dd8e50016075f3b118e85d9d63c21b2ba17de2e7aefb81
-DIST lxc-5.0.0.tar.gz.asc 833 BLAKE2B 3519789f7a9797895c1b89371db28add0833b0db5a32b71f8fdff98f689a2ed6edd77db90fad89658e7c148a94a1008a718dca32bc3ce40dbfce9b44c9506dbd SHA512 d475073543e82481675a4d7ffe642445b73698ad0675cfd996768c6f026786c694cea062d50139264362a516b8777fc4e1a5fb5592eeed35ac2f6d64460c505d
DIST lxc-5.0.1.tar.gz 973206 BLAKE2B 6d5cb1a03eb2612d0f8cb59783a64ec42bedd560cacfebf76383d9599dfc153e381f0e584a1c8c9a0b5b18a46bfb01863649dc5a019546e9ded6079b5ec69ddd SHA512 c87563b556aec83c93a7c62932217791e92da950cc76983f0d5e1d603fe1ae298a63fb5e88ec9ef5173846d579babb5acd0836679b915de00844bb9edf9c8d7e
DIST lxc-5.0.1.tar.gz.asc 833 BLAKE2B f85df5fc5bd88a738042f622ee4191b99e0a8e07db7ceb5824d634bc451f4bf93c8b64d1c72d4899f639ad30bbc9ee82be292dbe310218fa20566ee00f9bb752 SHA512 09de4e74d174b54cf9240ca4ef4793b9f63355c65f610abffb40e6dc2dc9130380761a50725e4dcee39b421e4b51c874d141fe22d5ecfd7ad3af35f7ebec09a0
diff --git a/app-containers/lxc/files/lxc-5.0.0-dont-depend-on-static-libcap.patch b/app-containers/lxc/files/lxc-5.0.0-dont-depend-on-static-libcap.patch
deleted file mode 100644
index 74f3d353c561..000000000000
--- a/app-containers/lxc/files/lxc-5.0.0-dont-depend-on-static-libcap.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 7d72354898feac15bc4082130bcbe638bae02450 Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Thu, 14 Jul 2022 17:03:40 +0200
-Subject: [PATCH] meson.build: fix build with -Dcapabilities=false
-
-Define libcap_static to an empty array to avoid the following build
-failure with -Dcapabilities=false:
-
-output/build/lxc-5.0.0/src/lxc/cmd/meson.build:64:4: ERROR: Unknown variable "libcap_static".
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- meson.build | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/meson.build b/meson.build
-index 992fa08c72..4ed57a655b 100644
---- a/meson.build
-+++ b/meson.build
-@@ -443,6 +443,7 @@ int main(int argc, char *argv[]) { return 0; };
- srcconf.set10('HAVE_STATIC_LIBCAP', false)
- endif
- else
-+ libcap_static = []
- srcconf.set10('HAVE_LIBCAP', false)
- srcconf.set10('HAVE_STATIC_LIBCAP', false)
- endif
diff --git a/app-containers/lxc/files/lxc-5.0.0-fix-strerror-r-char-p-musl.patch b/app-containers/lxc/files/lxc-5.0.0-fix-strerror-r-char-p-musl.patch
deleted file mode 100644
index fdd7aa24ad8a..000000000000
--- a/app-containers/lxc/files/lxc-5.0.0-fix-strerror-r-char-p-musl.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-https://github.com/lxc/lxc/commit/8ee8879083f40d2d0b9cef46d6a6907c1b5a814b
-
-From 8ee8879083f40d2d0b9cef46d6a6907c1b5a814b Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Thu, 14 Jul 2022 12:31:21 +0200
-Subject: [PATCH] src/lxc/log.h: fix STRERROR_R_CHAR_P
-
-STRERROR_R_CHAR_P is always defined to 0 or 1 depending on the value of
-have_func_strerror_r_char_p in meson.build so replace #ifdef by #if to
-avoid a redefinition build failure if char *strerror_r is not defined
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- src/lxc/log.h | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/lxc/log.h b/src/lxc/log.h
-index 554a2e1d48..fcddc679a8 100644
---- a/src/lxc/log.h
-+++ b/src/lxc/log.h
-@@ -304,13 +304,13 @@ __lxc_unused static inline void LXC_##LEVEL(struct lxc_log_locinfo* locinfo, \
- * Helper macro to define errno string.
- */
- #if HAVE_STRERROR_R
-- #ifdef STRERROR_R_CHAR_P
-+ #if STRERROR_R_CHAR_P
- char *strerror_r(int errnum, char *buf, size_t buflen);
- #else
- int strerror_r(int errnum, char *buf, size_t buflen);
- #endif
-
-- #ifdef STRERROR_R_CHAR_P
-+ #if STRERROR_R_CHAR_P
- #define lxc_log_strerror_r \
- char errno_buf[PATH_MAX / 2] = {"Failed to get errno string"}; \
- char *ptr = NULL; \
diff --git a/app-containers/lxc/lxc-5.0.0-r1.ebuild b/app-containers/lxc/lxc-5.0.0-r1.ebuild
deleted file mode 100644
index 1ab8d12bf9d6..000000000000
--- a/app-containers/lxc/lxc-5.0.0-r1.ebuild
+++ /dev/null
@@ -1,160 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 linux-info meson optfeature systemd verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P}.tar.gz.asc )"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86"
-IUSE="apparmor +caps examples io-uring man pam seccomp selinux ssl systemd test +tools verify-sig"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- apparmor? ( sys-libs/libapparmor )
- caps? ( sys-libs/libcap[static-libs] )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? ( dev-libs/openssl:0= )
- systemd? ( sys-apps/systemd )
- tools? ( sys-libs/libcap[static-libs] )"
-DEPEND="${RDEPEND}
- sys-kernel/linux-headers"
-BDEPEND="virtual/pkgconfig
- man? ( app-text/docbook2X )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-RESTRICT="!test? ( test )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
-
-PATCHES=( "${FILESDIR}"/lxc-5.0.0-dont-depend-on-static-libcap.patch
- "${FILESDIR}"/${PN}-5.0.0-fix-strerror-r-char-p-musl.patch )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-src_configure() {
- local emesonargs=(
- -Dcoverity-build=false
- -Doss-fuzz=false
-
- -Dcommands=true
- -Dmemfd-rexec=true
- -Dthread-safety=true
-
- $(meson_use apparmor)
- $(meson_use caps capabilities)
- $(meson_use examples)
- $(meson_use io-uring io-uring-event-loop)
- $(meson_use man)
- $(meson_use pam pam-cgroup)
- $(meson_use seccomp)
- $(meson_use selinux)
- $(meson_use ssl openssl)
- $(meson_use test tests)
- $(meson_use tools)
-
- -Ddata-path=/var/lib/lxc
- -Ddoc-path=/usr/share/doc/${PF}
- -Dlog-path=/var/log/lxc
- -Drootfs-mount-path=/var/lib/lxc/rootfs
- -Druntime-path=/run
- )
-
- if use systemd; then
- local emesonargs+=( -Dinit-script="systemd" )
- else
- local emesonargs+=( -Dinit-script="sysvinit" )
- fi
-
- use tools && local emesonargs+=( -Dcapabilities=true )
-
- meson_src_configure
-}
-
-src_install() {
- meson_src_install
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,stop,unfreeze,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /var/lib/cache/lxc /var/lib/lib/lxc
-
- find "${ED}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Replace upstream sysvinit/systemd files.
- if use systemd; then
- rm -r "${D}$(systemd_get_systemunitdir)" || die "Failed to remove systemd lib dir"
- else
- rm "${ED}"/etc/init.d/lxc-{containers,net} || die "Failed to remove sysvinit scripts"
- fi
-
- newinitd "${FILESDIR}/${PN}.initd.8" ${PN}
- systemd_newunit "${FILESDIR}"/lxc-monitord.service.5.0.0 lxc-monitord.service
- systemd_newunit "${FILESDIR}"/lxc-net.service.5.0.0 lxc-net.service
- systemd_newunit "${FILESDIR}"/lxc.service-5.0.0 lxc.service
- systemd_newunit "${FILESDIR}"/lxc_at.service.5.0.0 "lxc@.service"
-
- if ! use apparmor; then
- sed -i '/lxc-apparmor-load/d' "${D}$(systemd_get_systemunitdir)/lxc.service" || die "Failed to remove apparmor references from lxc.service systemd unit."
- fi
-}
-
-pkg_postinst() {
- elog "Please refer to "
- elog "https://wiki.gentoo.org/wiki/LXC for introduction and usage guide."
- elog
- elog "Run 'lxc-checkconfig' to see optional kernel features."
- elog
-
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
diff --git a/app-containers/lxc/lxc-5.0.0.ebuild b/app-containers/lxc/lxc-5.0.0.ebuild
deleted file mode 100644
index 975d697a0e5b..000000000000
--- a/app-containers/lxc/lxc-5.0.0.ebuild
+++ /dev/null
@@ -1,160 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 linux-info meson optfeature systemd verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P}.tar.gz.asc )"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~riscv ~x86"
-IUSE="apparmor +caps examples io-uring man pam seccomp selinux ssl systemd test +tools verify-sig"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- apparmor? ( sys-libs/libapparmor )
- caps? ( sys-libs/libcap[static-libs] )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? ( dev-libs/openssl:0= )
- systemd? ( sys-apps/systemd )
- tools? ( sys-libs/libcap[static-libs] )"
-DEPEND="${RDEPEND}
- sys-kernel/linux-headers"
-BDEPEND="virtual/pkgconfig
- man? ( app-text/docbook2X )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-RESTRICT="!test? ( test )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
-
-PATCHES=( "${FILESDIR}"/lxc-5.0.0-dont-depend-on-static-libcap.patch
- "${FILESDIR}"/${PN}-5.0.0-fix-strerror-r-char-p-musl.patch )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-src_configure() {
- local emesonargs=(
- -Dcoverity-build=false
- -Doss-fuzz=false
-
- -Dcommands=true
- -Dmemfd-rexec=true
- -Dthread-safety=true
-
- $(meson_use apparmor)
- $(meson_use caps capabilities)
- $(meson_use examples)
- $(meson_use io-uring io-uring-event-loop)
- $(meson_use man)
- $(meson_use pam pam-cgroup)
- $(meson_use seccomp)
- $(meson_use selinux)
- $(meson_use ssl openssl)
- $(meson_use test tests)
- $(meson_use tools)
-
- -Ddata-path=/var/lib/lxc
- -Ddoc-path=/usr/share/doc/${PF}
- -Dlog-path=/var/log/lxc
- -Drootfs-mount-path=/var/lib/lxc/rootfs
- -Druntime-path=/run
- )
-
- if use systemd; then
- local emesonargs+=( -Dinit-script="systemd" )
- else
- local emesonargs+=( -Dinit-script="sysvinit" )
- fi
-
- use tools && local emesonargs+=( -Dcapabilities=true )
-
- meson_src_configure
-}
-
-src_install() {
- meson_src_install
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,stop,unfreeze,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /var/lib/cache/lxc /var/lib/lib/lxc
-
- find "${ED}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Replace upstream sysvinit/systemd files.
- if use systemd; then
- rm -r "${ED}"/lib/systemd || die "Failed to remove systemd lib dir"
- else
- rm "${ED}"/etc/init.d/lxc-{containers,net} || die "Failed to remove sysvinit scripts"
- fi
-
- newinitd "${FILESDIR}/${PN}.initd.8" ${PN}
- systemd_newunit "${FILESDIR}"/lxc-monitord.service.5.0.0 lxc-monitord.service
- systemd_newunit "${FILESDIR}"/lxc-net.service.5.0.0 lxc-net.service
- systemd_newunit "${FILESDIR}"/lxc.service-5.0.0 lxc.service
- systemd_newunit "${FILESDIR}"/lxc_at.service.5.0.0 "lxc@.service"
-
- if ! use apparmor; then
- sed -i '/lxc-apparmor-load/d' "${ED}"/lib/systemd/system/lxc.service || die "Failed to remove apparmor references from lxc.service systemd unit."
- fi
-}
-
-pkg_postinst() {
- elog "Please refer to "
- elog "https://wiki.gentoo.org/wiki/LXC for introduction and usage guide."
- elog
- elog "Run 'lxc-checkconfig' to see optional kernel features."
- elog
-
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2022-09-10 5:24 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2022-09-10 5:24 UTC (permalink / raw
To: gentoo-commits
commit: 570b8888ef9ccac133fb8eadc25beb2dbb16119c
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Sat Sep 10 05:19:00 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Sat Sep 10 05:19:00 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=570b8888
app-containers/lxc: drop 4.0.12
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
app-containers/lxc/Manifest | 2 -
.../lxc/files/lxc-2.0.5-omit-sysconfig.patch | 5 -
app-containers/lxc/files/lxc_at.service.4.0.0 | 15 --
app-containers/lxc/lxc-4.0.12.ebuild | 184 ---------------------
4 files changed, 206 deletions(-)
diff --git a/app-containers/lxc/Manifest b/app-containers/lxc/Manifest
index 0c60e874b27b..6d1c784c3648 100644
--- a/app-containers/lxc/Manifest
+++ b/app-containers/lxc/Manifest
@@ -1,4 +1,2 @@
-DIST lxc-4.0.12.tar.gz 1565070 BLAKE2B 819b5140b641dbc1ed6cf5f2840bb0ee6d3ab8c687f4f8064e42d347113bdf50fcbb653a6fb26598db0daab0c83ad88fe0d27fd2842fac9d7f5fef73656d7976 SHA512 04437d9c891cd3a22f756c42f05e97398772587175d65aff9d394f0f3e810efc5c1fe7077c39573de3ec259e0605bc2a7ea51093613b2cef908372ae338df19d
-DIST lxc-4.0.12.tar.gz.asc 833 BLAKE2B 2fca60b5ac267a893f70875ccdbe39db6b98b5fe51fe396692449e310b6e680e7b142380e193f5d8299f18e796ed2fd0e08cd186859069877fcca6bc26e44717 SHA512 4f2912879e6f3bf5fdbebb902cf16ca6b766b5720b817c4b4996e62098a1d282327d330ffd9768d45d69aeddb50184dc8485b0ef75b046449ce4c544cdc43c9b
DIST lxc-5.0.1.tar.gz 973206 BLAKE2B 6d5cb1a03eb2612d0f8cb59783a64ec42bedd560cacfebf76383d9599dfc153e381f0e584a1c8c9a0b5b18a46bfb01863649dc5a019546e9ded6079b5ec69ddd SHA512 c87563b556aec83c93a7c62932217791e92da950cc76983f0d5e1d603fe1ae298a63fb5e88ec9ef5173846d579babb5acd0836679b915de00844bb9edf9c8d7e
DIST lxc-5.0.1.tar.gz.asc 833 BLAKE2B f85df5fc5bd88a738042f622ee4191b99e0a8e07db7ceb5824d634bc451f4bf93c8b64d1c72d4899f639ad30bbc9ee82be292dbe310218fa20566ee00f9bb752 SHA512 09de4e74d174b54cf9240ca4ef4793b9f63355c65f610abffb40e6dc2dc9130380761a50725e4dcee39b421e4b51c874d141fe22d5ecfd7ad3af35f7ebec09a0
diff --git a/app-containers/lxc/files/lxc-2.0.5-omit-sysconfig.patch b/app-containers/lxc/files/lxc-2.0.5-omit-sysconfig.patch
deleted file mode 100644
index 3ec81356499e..000000000000
--- a/app-containers/lxc/files/lxc-2.0.5-omit-sysconfig.patch
+++ /dev/null
@@ -1,5 +0,0 @@
---- /config/Makefile.am.orig 2016-05-19 02:56:11.891113982 +0000
-+++ /config/Makefile.am 2016-05-19 02:56:32.596115476 +0000
-@@ -1 +1 @@
--SUBDIRS = apparmor bash etc init selinux templates yum sysconfig
-+SUBDIRS = apparmor bash etc init selinux templates yum
diff --git a/app-containers/lxc/files/lxc_at.service.4.0.0 b/app-containers/lxc/files/lxc_at.service.4.0.0
deleted file mode 100644
index b354bc53e080..000000000000
--- a/app-containers/lxc/files/lxc_at.service.4.0.0
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=Linux Container %i
-After=network.target
-Wants=lxcfs.service
-
-[Service]
-Type=forking
-ExecStart=/usr/bin/lxc-start -d -n %i -p /run/lxc-%i.pid
-PIDFile=/run/lxc-%i.pid
-ExecStop=/usr/bin/lxc-stop -n %i
-Delegate=true
-TasksMax=32768
-
-[Install]
-WantedBy=multi-user.target
diff --git a/app-containers/lxc/lxc-4.0.12.ebuild b/app-containers/lxc/lxc-4.0.12.ebuild
deleted file mode 100644
index 961d8c51761d..000000000000
--- a/app-containers/lxc/lxc-4.0.12.ebuild
+++ /dev/null
@@ -1,184 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools bash-completion-r1 linux-info flag-o-matic optfeature pam readme.gentoo-r1 systemd verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P}.tar.gz.asc )"
-
-KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0"
-IUSE="apparmor +caps doc io-uring man pam seccomp selinux +ssl +tools verify-sig"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- app-misc/pax-utils
- sys-apps/util-linux
- sys-libs/libcap
- virtual/awk
- caps? ( sys-libs/libcap )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? (
- dev-libs/openssl:0=
- )"
-DEPEND="${RDEPEND}
- >=sys-kernel/linux-headers-4
- apparmor? ( sys-apps/apparmor )"
-BDEPEND="virtual/pkgconfig
- doc? ( app-doc/doxygen[dot] )
- man? ( app-text/docbook-sgml-utils )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch # bug 558854
-)
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-src_prepare() {
- default
-
- export bashcompdir="/etc/bash_completion.d"
- eautoreconf
-}
-
-src_configure() {
- append-flags -fno-strict-aliasing
-
- local myeconfargs=(
- --bindir=/usr/bin
- --localstatedir=/var
- --sbindir=/usr/bin
-
- --with-config-path=/var/lib/lxc
- --with-distro=gentoo
- --with-init-script=systemd
- --with-rootfs-path=/var/lib/lxc/rootfs
- --with-runtime-path=/run
- --with-systemdsystemunitdir=$(systemd_get_systemunitdir)
-
- --disable-coverity-build
- --disable-dlog
- --disable-fuzzers
- --disable-mutex-debugging
- --disable-no-undefined
- --disable-rpath
- --disable-sanitizers
- --disable-tests
- --disable-werror
-
- --enable-bash
- --enable-commands
- --enable-memfd-rexec
- --enable-thread-safety
-
- $(use_enable apparmor)
- $(use_enable caps capabilities)
- $(use_enable doc api-docs)
- $(use_enable doc examples)
- $(use_enable io-uring liburing)
- $(use_enable man doc)
- $(use_enable pam)
- $(use_enable seccomp)
- $(use_enable selinux)
- $(use_enable ssl openssl)
- $(use_enable tools)
-
- $(use_with pam pamdir $(getpam_mod_dir))
- )
-
- econf "${myeconfargs[@]}"
-}
-
-src_install() {
- default
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
- mv "${ED}"/etc/bash_completion.d/lxc "${ED}"/$(get_bashcompdir)/lxc-start || die "Failed to relocate lxc bash-completion file."
- rm -r "${ED}"/etc/bash_completion.d || die "Failed to remove wrong bash_completion.d content."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,stop,unfreeze,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc
- rmdir "${D}"/var/cache/lxc "${D}"/var/cache || die "rmdir failed"
-
- find "${D}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Gentoo-specific additions!
- newinitd "${FILESDIR}/lxc.initd.8" lxc
-
- # Remember to compare our systemd unit file with the upstream one
- # config/init/systemd/lxc.service.in
- systemd_newunit "${FILESDIR}"/lxc_at.service.4.0.0 "lxc@.service"
-
- DOC_CONTENTS="
- For openrc, there is an init script provided with the package.
- You should only need to symlink /etc/init.d/lxc to
- /etc/init.d/lxc.configname to start the container defined in
- /etc/lxc/configname.conf.
-
- Correspondingly, for systemd a service file lxc@.service is installed.
- Enable and start lxc@configname in order to start the container defined
- in /etc/lxc/configname.conf."
- DISABLE_AUTOFORMATTING=true
- readme.gentoo_create_doc
-}
-
-pkg_postinst() {
- readme.gentoo_print_elog
-
- elog "Please run 'lxc-checkconfig' to see optional kernel features."
- elog
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2022-10-04 16:10 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2022-10-04 16:10 UTC (permalink / raw
To: gentoo-commits
commit: 391bd314114a302c9c4b87da6991659d1356f064
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Tue Oct 4 16:05:41 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Oct 4 16:09:58 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=391bd314
app-containers/lxc: fix on glibc-2.36
Closes: https://bugs.gentoo.org/864919
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
.../lxc/files/lxc-5.0.1-glibc-2.36.patch | 383 +++++++++++++++++++++
app-containers/lxc/lxc-5.0.1-r1.ebuild | 2 +
2 files changed, 385 insertions(+)
diff --git a/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch b/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch
new file mode 100644
index 000000000000..e186c7fbb282
--- /dev/null
+++ b/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch
@@ -0,0 +1,383 @@
+From c1115e1503bf955c97f4cf3b925a6a9f619764c3 Mon Sep 17 00:00:00 2001
+From: Christian Brauner <brauner@kernel.org>
+Date: Tue, 9 Aug 2022 16:14:25 +0200
+Subject: [PATCH 1/3] build: detect where struct mount_attr is declared
+
+Fixes: #4176
+Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
+---
+ meson.build | 30 ++++++++++++++++++++++++++++--
+ src/lxc/conf.c | 6 +++---
+ src/lxc/conf.h | 2 +-
+ src/lxc/mount_utils.c | 6 +++---
+ src/lxc/syscall_wrappers.h | 12 ++++++++++--
+ 5 files changed, 45 insertions(+), 11 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index a145faf069..f679aabbc8 100644
+--- a/meson.build
++++ b/meson.build
+@@ -590,7 +590,6 @@ decl_headers = '''
+ foreach decl: [
+ '__aligned_u64',
+ 'struct clone_args',
+- 'struct mount_attr',
+ 'struct open_how',
+ 'struct rtnl_link_stats64',
+ ]
+@@ -610,7 +609,6 @@ foreach tuple: [
+ ['struct seccomp_notif_sizes'],
+ ['struct clone_args'],
+ ['__aligned_u64'],
+- ['struct mount_attr'],
+ ['struct open_how'],
+ ['struct rtnl_link_stats64'],
+ ]
+@@ -630,6 +628,34 @@ foreach tuple: [
+ endif
+ endforeach
+
++## Types.
++decl_headers = '''
++#include <sys/mount.h>
++'''
++
++# We get -1 if the size cannot be determined
++if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') > 0
++ srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), true)
++ found_types += 'struct mount_attr (sys/mount.h)'
++else
++ srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), false)
++ missing_types += 'struct mount_attr (sys/mount.h)'
++endif
++
++## Types.
++decl_headers = '''
++#include <linux/mount.h>
++'''
++
++# We get -1 if the size cannot be determined
++if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') > 0
++ srcconf.set10('HAVE_UAPI_' + 'struct mount_attr'.underscorify().to_upper(), true)
++ found_types += 'struct mount_attr (linux/mount.h)'
++else
++ srcconf.set10('HAVE_UAPI_' + 'struct mount_attr'.underscorify().to_upper(), false)
++ missing_types += 'struct mount_attr (linux/mount.h)'
++endif
++
+ ## Headers.
+ foreach ident: [
+ ['bpf', '''#include <sys/syscall.h>
+diff --git a/src/lxc/conf.c b/src/lxc/conf.c
+index ffbe74c2f6..4193cd07f5 100644
+--- a/src/lxc/conf.c
++++ b/src/lxc/conf.c
+@@ -2885,7 +2885,7 @@ static int __lxc_idmapped_mounts_child(struct lxc_handler *handler, FILE *f)
+ struct lxc_mount_options opts = {};
+ int dfd_from;
+ const char *source_relative, *target_relative;
+- struct lxc_mount_attr attr = {};
++ struct mount_attr attr = {};
+
+ ret = parse_lxc_mount_attrs(&opts, mntent.mnt_opts);
+ if (ret < 0)
+@@ -3005,7 +3005,7 @@ static int __lxc_idmapped_mounts_child(struct lxc_handler *handler, FILE *f)
+
+ /* Set propagation mount options. */
+ if (opts.attr.propagation) {
+- attr = (struct lxc_mount_attr) {
++ attr = (struct mount_attr) {
+ .propagation = opts.attr.propagation,
+ };
+
+@@ -4109,7 +4109,7 @@ int lxc_idmapped_mounts_parent(struct lxc_handler *handler)
+
+ for (;;) {
+ __do_close int fd_from = -EBADF, fd_userns = -EBADF;
+- struct lxc_mount_attr attr = {};
++ struct mount_attr attr = {};
+ struct lxc_mount_options opts = {};
+ ssize_t ret;
+
+diff --git a/src/lxc/conf.h b/src/lxc/conf.h
+index 7dc2f15b60..772479f9e1 100644
+--- a/src/lxc/conf.h
++++ b/src/lxc/conf.h
+@@ -223,7 +223,7 @@ struct lxc_mount_options {
+ unsigned long mnt_flags;
+ unsigned long prop_flags;
+ char *data;
+- struct lxc_mount_attr attr;
++ struct mount_attr attr;
+ char *raw_options;
+ };
+
+diff --git a/src/lxc/mount_utils.c b/src/lxc/mount_utils.c
+index bba75f933c..88dd73ee36 100644
+--- a/src/lxc/mount_utils.c
++++ b/src/lxc/mount_utils.c
+@@ -31,7 +31,7 @@ lxc_log_define(mount_utils, lxc);
+ * setting in @attr_set, but must also specify MOUNT_ATTR__ATIME in the
+ * @attr_clr field.
+ */
+-static inline void set_atime(struct lxc_mount_attr *attr)
++static inline void set_atime(struct mount_attr *attr)
+ {
+ switch (attr->attr_set & MOUNT_ATTR__ATIME) {
+ case MOUNT_ATTR_RELATIME:
+@@ -272,7 +272,7 @@ int create_detached_idmapped_mount(const char *path, int userns_fd,
+ {
+ __do_close int fd_tree_from = -EBADF;
+ unsigned int open_tree_flags = OPEN_TREE_CLONE | OPEN_TREE_CLOEXEC;
+- struct lxc_mount_attr attr = {
++ struct mount_attr attr = {
+ .attr_set = MOUNT_ATTR_IDMAP | attr_set,
+ .attr_clr = attr_clr,
+ .userns_fd = userns_fd,
+@@ -335,7 +335,7 @@ int __fd_bind_mount(int dfd_from, const char *path_from, __u64 o_flags_from,
+ __u64 attr_clr, __u64 propagation, int userns_fd,
+ bool recursive)
+ {
+- struct lxc_mount_attr attr = {
++ struct mount_attr attr = {
+ .attr_set = attr_set,
+ .attr_clr = attr_clr,
+ .propagation = propagation,
+diff --git a/src/lxc/syscall_wrappers.h b/src/lxc/syscall_wrappers.h
+index a5e98b565c..c8a7d0c7b7 100644
+--- a/src/lxc/syscall_wrappers.h
++++ b/src/lxc/syscall_wrappers.h
+@@ -18,6 +18,12 @@
+ #include "macro.h"
+ #include "syscall_numbers.h"
+
++#if HAVE_STRUCT_MOUNT_ATTR
++#include <sys/mount.h>
++#elif HAVE_UAPI_STRUCT_MOUNT_ATTR
++#include <linux/mount.h>
++#endif
++
+ #ifdef HAVE_LINUX_MEMFD_H
+ #include <linux/memfd.h>
+ #endif
+@@ -210,16 +216,18 @@ extern int fsmount(int fs_fd, unsigned int flags, unsigned int attr_flags);
+ /*
+ * mount_setattr()
+ */
+-struct lxc_mount_attr {
++#if !HAVE_STRUCT_MOUNT_ATTR && !HAVE_UAPI_STRUCT_MOUNT_ATTR
++struct mount_attr {
+ __u64 attr_set;
+ __u64 attr_clr;
+ __u64 propagation;
+ __u64 userns_fd;
+ };
++#endif
+
+ #if !HAVE_MOUNT_SETATTR
+ static inline int mount_setattr(int dfd, const char *path, unsigned int flags,
+- struct lxc_mount_attr *attr, size_t size)
++ struct mount_attr *attr, size_t size)
+ {
+ return syscall(__NR_mount_setattr, dfd, path, flags, attr, size);
+ }
+
+From ef1e0607b82e27350c2d677d649c6a0a9693fd40 Mon Sep 17 00:00:00 2001
+From: Christian Brauner <brauner@kernel.org>
+Date: Tue, 9 Aug 2022 16:27:40 +0200
+Subject: [PATCH 2/3] build: detect sys/pidfd.h availability
+
+Fixes: #4176
+Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
+---
+ meson.build | 1 +
+ src/lxc/process_utils.h | 6 ++++++
+ 2 files changed, 7 insertions(+)
+
+diff --git a/meson.build b/meson.build
+index f679aabbc8..e999542336 100644
+--- a/meson.build
++++ b/meson.build
+@@ -735,6 +735,7 @@ foreach tuple: [
+ ['sys/resource.h'],
+ ['sys/memfd.h'],
+ ['sys/personality.h'],
++ ['sys/pidfd.h'],
+ ['sys/signalfd.h'],
+ ['sys/timerfd.h'],
+ ['pty.h'],
+diff --git a/src/lxc/process_utils.h b/src/lxc/process_utils.h
+index 9c15b15741..ed84741d0e 100644
+--- a/src/lxc/process_utils.h
++++ b/src/lxc/process_utils.h
+@@ -15,6 +15,10 @@
+ #include <sys/syscall.h>
+ #include <unistd.h>
+
++#if HAVE_SYS_PIDFD_H
++#include <sys/pidfd.h>
++#endif
++
+ #include "compiler.h"
+ #include "syscall_numbers.h"
+
+@@ -136,9 +140,11 @@
+ #endif
+
+ /* waitid */
++#if !HAVE_SYS_PIDFD_H
+ #ifndef P_PIDFD
+ #define P_PIDFD 3
+ #endif
++#endif
+
+ #ifndef CLONE_ARGS_SIZE_VER0
+ #define CLONE_ARGS_SIZE_VER0 64 /* sizeof first published struct */
+
+From cbabe8abf11e7e7fb49c123bae31efdd9bc8f1e8 Mon Sep 17 00:00:00 2001
+From: Christian Brauner <brauner@kernel.org>
+Date: Tue, 9 Aug 2022 17:19:40 +0200
+Subject: [PATCH 3/3] build: check for FS_CONFIG_* header symbol in sys/mount.h
+
+Fixes: #4176
+Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
+---
+ meson.build | 59 +++++++++++++++++++++++++++++++++++++++++--
+ src/lxc/mount_utils.h | 16 ++++++++++++
+ 2 files changed, 73 insertions(+), 2 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index e999542336..9f8a5de60c 100644
+--- a/meson.build
++++ b/meson.build
+@@ -639,8 +639,7 @@ if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') >
+ found_types += 'struct mount_attr (sys/mount.h)'
+ else
+ srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), false)
+- missing_types += 'struct mount_attr (sys/mount.h)'
+-endif
++ missing_types += 'struct mount_attr (sys/mount.h)' endif
+
+ ## Types.
+ decl_headers = '''
+@@ -656,6 +655,62 @@ else
+ missing_types += 'struct mount_attr (linux/mount.h)'
+ endif
+
++if cc.has_header_symbol('sys/mount.h', 'FSCONFIG_SET_FLAG')
++ srcconf.set10('HAVE_' + 'FSCONFIG_SET_FLAG'.underscorify().to_upper(), true)
++ found_types += 'FSCONFIG_SET_FLAG'
++else
++ srcconf.set10('HAVE_' + 'FSCONFIG_SET_FLAG'.underscorify().to_upper(), false)
++ missing_types += 'FSCONFIG_SET_FLAG'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_STRING')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_STRING'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_STRING'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_STRING'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_STRING'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_BINARY')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_BINARY'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_BINARY'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_BINARY'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_BINARY'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_PATH_EMPTY')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_EMPTY'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_PATH_EMPTY'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_EMPTY'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_PATH_EMPTY'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_PATH_FD')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_FD'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_PATH_FD'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_FD'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_PATH_FD'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_CMD_CREATE')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_CREATE'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_CMD_CREATE'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_CREATE'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_CMD_CREATE'
++endif
++
++if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_CMD_RECONFIGURE')
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_RECONFIGURE'.underscorify().to_upper(), true)
++ found_types += 'FS_CONFIG_SET_CMD_RECONFIGURE'
++else
++ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_RECONFIGURE'.underscorify().to_upper(), false)
++ missing_types += 'FS_CONFIG_SET_CMD_RECONFIGURE'
++endif
++
+ ## Headers.
+ foreach ident: [
+ ['bpf', '''#include <sys/syscall.h>
+diff --git a/src/lxc/mount_utils.h b/src/lxc/mount_utils.h
+index ea392672d8..fd34739459 100644
+--- a/src/lxc/mount_utils.h
++++ b/src/lxc/mount_utils.h
+@@ -82,37 +82,53 @@ struct lxc_rootfs;
+ #endif
+
+ /* fsconfig() commands */
++#if !HAVE_FSCONFIG_SET_FLAG
+ #ifndef FSCONFIG_SET_FLAG
+ #define FSCONFIG_SET_FLAG 0 /* Set parameter, supplying no value */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_SET_STRING
+ #ifndef FSCONFIG_SET_STRING
+ #define FSCONFIG_SET_STRING 1 /* Set parameter, supplying a string value */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_SET_BINARY
+ #ifndef FSCONFIG_SET_BINARY
+ #define FSCONFIG_SET_BINARY 2 /* Set parameter, supplying a binary blob value */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_SET_PATH
+ #ifndef FSCONFIG_SET_PATH
+ #define FSCONFIG_SET_PATH 3 /* Set parameter, supplying an object by path */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_SET_PATH_EMPTY
+ #ifndef FSCONFIG_SET_PATH_EMPTY
+ #define FSCONFIG_SET_PATH_EMPTY 4 /* Set parameter, supplying an object by (empty) path */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_SET_FD
+ #ifndef FSCONFIG_SET_FD
+ #define FSCONFIG_SET_FD 5 /* Set parameter, supplying an object by fd */
+ #endif
++#endif
+
++#if !HAVE_FSCONFIG_CMD_CREATE
+ #ifndef FSCONFIG_CMD_CREATE
+ #define FSCONFIG_CMD_CREATE 6 /* Invoke superblock creation */
+ #endif
++#endif
+
++#if !FSCONFIG_CMD_RECONFIGURE
+ #ifndef FSCONFIG_CMD_RECONFIGURE
+ #define FSCONFIG_CMD_RECONFIGURE 7 /* Invoke superblock reconfiguration */
+ #endif
++#endif
+
+ /* fsmount() flags */
+ #ifndef FSMOUNT_CLOEXEC
diff --git a/app-containers/lxc/lxc-5.0.1-r1.ebuild b/app-containers/lxc/lxc-5.0.1-r1.ebuild
index 3f264e03d0c1..7a9e415fda2a 100644
--- a/app-containers/lxc/lxc-5.0.1-r1.ebuild
+++ b/app-containers/lxc/lxc-5.0.1-r1.ebuild
@@ -67,6 +67,8 @@ VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
+PATCHES=( "${FILESDIR}"/lxc-5.0.1-glibc-2.36.patch )
+
pkg_setup() {
linux-info_pkg_setup
}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2022-10-06 11:13 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2022-10-06 11:13 UTC (permalink / raw
To: gentoo-commits
commit: 80f4ab584f09b64c538d5d1970de8eb66bae5d4a
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Thu Oct 6 11:11:29 2022 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu Oct 6 11:11:29 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=80f4ab58
app-containers/lxc: add a patch to fix arm64+systemd issue
Closes: https://bugs.gentoo.org/875356
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
...d_bus_call_method_async-insteaf-of-asyncv.patch | 44 ++++++++++++++++++++++
app-containers/lxc/lxc-5.0.1-r1.ebuild | 3 +-
2 files changed, 46 insertions(+), 1 deletion(-)
diff --git a/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch b/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch
new file mode 100644
index 000000000000..fe218ea0c3e6
--- /dev/null
+++ b/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch
@@ -0,0 +1,44 @@
+From b0abedf60b40adf0f2fb3cf9dfee4bc601f7b39f Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Thu, 25 Aug 2022 05:45:53 -0700
+Subject: [PATCH] use sd_bus_call_method_async to replace the asyncv one
+
+The sd_bus_call_method_asyncv's 10th parameter is of type
+va_list and supplying NULL when invoking it causes compilation
+error. Just replace it with the async one.
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build | 4 ++--
+ src/lxc/cgroups/cgfsng.c | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index 21955a0504..f8bdcf4e83 100644
+--- a/meson.build
++++ b/meson.build
+@@ -295,9 +295,9 @@ if not want_sd_bus.disabled()
+ has_sd_bus = false
+ endif
+
+- if not cc.has_function('sd_bus_call_method_asyncv', prefix: '#include <systemd/sd-bus.h>', dependencies: libsystemd)
++ if not cc.has_function('sd_bus_call_method_async', prefix: '#include <systemd/sd-bus.h>', dependencies: libsystemd)
+ if not sd_bus_optional
+- error('libsystemd misses required sd_bus_call_method_asyncv function')
++ error('libsystemd misses required sd_bus_call_method_async function')
+ endif
+
+ has_sd_bus = false
+diff --git a/src/lxc/cgroups/cgfsng.c b/src/lxc/cgroups/cgfsng.c
+index 8a3615893f..d90e5385e1 100644
+--- a/src/lxc/cgroups/cgfsng.c
++++ b/src/lxc/cgroups/cgfsng.c
+@@ -1232,7 +1232,7 @@ static int unpriv_systemd_create_scope(struct cgroup_ops *ops, struct lxc_conf *
+ if (r < 0)
+ return log_error(SYSTEMD_SCOPE_FAILED, "Failed to connect to user bus: %s", strerror(-r));
+
+- r = sd_bus_call_method_asyncv(bus, NULL, DESTINATION, PATH, INTERFACE, "Subscribe", NULL, NULL, NULL, NULL);
++ r = sd_bus_call_method_async(bus, NULL, DESTINATION, PATH, INTERFACE, "Subscribe", NULL, NULL, NULL);
+ if (r < 0)
+ return log_error(SYSTEMD_SCOPE_FAILED, "Failed to subscribe to signals: %s", strerror(-r));
+
diff --git a/app-containers/lxc/lxc-5.0.1-r1.ebuild b/app-containers/lxc/lxc-5.0.1-r1.ebuild
index 7a9e415fda2a..f4714bf4705c 100644
--- a/app-containers/lxc/lxc-5.0.1-r1.ebuild
+++ b/app-containers/lxc/lxc-5.0.1-r1.ebuild
@@ -67,7 +67,8 @@ VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
-PATCHES=( "${FILESDIR}"/lxc-5.0.1-glibc-2.36.patch )
+PATCHES=( "${FILESDIR}"/lxc-5.0.1-glibc-2.36.patch
+ "${FILESDIR}"/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch )
pkg_setup() {
linux-info_pkg_setup
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2023-02-22 7:14 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2023-02-22 7:14 UTC (permalink / raw
To: gentoo-commits
commit: f565998a51b1e190e4595d726873e1775b2bc4c8
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Wed Feb 22 07:11:49 2023 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Wed Feb 22 07:11:49 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f565998a
app-containers/lxc: drop 5.0.1-r2
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
app-containers/lxc/Manifest | 2 -
.../lxc/files/lxc-5.0.1-glibc-2.36.patch | 383 ---------------------
...d_bus_call_method_async-insteaf-of-asyncv.patch | 44 ---
app-containers/lxc/lxc-5.0.1-r2.ebuild | 171 ---------
4 files changed, 600 deletions(-)
diff --git a/app-containers/lxc/Manifest b/app-containers/lxc/Manifest
index 94adb342d397..42ff946b34f8 100644
--- a/app-containers/lxc/Manifest
+++ b/app-containers/lxc/Manifest
@@ -1,4 +1,2 @@
-DIST lxc-5.0.1.tar.gz 973206 BLAKE2B 6d5cb1a03eb2612d0f8cb59783a64ec42bedd560cacfebf76383d9599dfc153e381f0e584a1c8c9a0b5b18a46bfb01863649dc5a019546e9ded6079b5ec69ddd SHA512 c87563b556aec83c93a7c62932217791e92da950cc76983f0d5e1d603fe1ae298a63fb5e88ec9ef5173846d579babb5acd0836679b915de00844bb9edf9c8d7e
-DIST lxc-5.0.1.tar.gz.asc 833 BLAKE2B f85df5fc5bd88a738042f622ee4191b99e0a8e07db7ceb5824d634bc451f4bf93c8b64d1c72d4899f639ad30bbc9ee82be292dbe310218fa20566ee00f9bb752 SHA512 09de4e74d174b54cf9240ca4ef4793b9f63355c65f610abffb40e6dc2dc9130380761a50725e4dcee39b421e4b51c874d141fe22d5ecfd7ad3af35f7ebec09a0
DIST lxc-5.0.2.tar.gz 973977 BLAKE2B e6017406b96f53525b576528814922a017a7d65fb04724046236307f4e85219b3c8ac725678e57ae3f77a4e817f718748e8c61fbc8147160e4ac87d3146b6567 SHA512 2e8800875e9c91cc0cbfdfc33c43d84bad9471d8a1b8ccd52d7d9c6fe44f280f9f701b8ccc2e0f5319a3e4c50d8c4331722f0dd9c0347575eb4f7b4ed110bef3
DIST lxc-5.0.2.tar.gz.asc 833 BLAKE2B 3d78f8a87b2f45d2b91a9a6595d286e2fc1dcfc7d28f3c1d86e968860a7e346506ab28d4dafffede8acf1f82e8b12f90eda2e6210cd6bdec702f59bad97295c6 SHA512 9bd1ef117cf256841b75d409e8f14b88ed54fdfc9c8c472b6baa5e9695e39cdb8c1f47ce612dc8263abb65511df0812554cc9a5820cdd6c1539a07283a4cd08f
diff --git a/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch b/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch
deleted file mode 100644
index e186c7fbb282..000000000000
--- a/app-containers/lxc/files/lxc-5.0.1-glibc-2.36.patch
+++ /dev/null
@@ -1,383 +0,0 @@
-From c1115e1503bf955c97f4cf3b925a6a9f619764c3 Mon Sep 17 00:00:00 2001
-From: Christian Brauner <brauner@kernel.org>
-Date: Tue, 9 Aug 2022 16:14:25 +0200
-Subject: [PATCH 1/3] build: detect where struct mount_attr is declared
-
-Fixes: #4176
-Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
----
- meson.build | 30 ++++++++++++++++++++++++++++--
- src/lxc/conf.c | 6 +++---
- src/lxc/conf.h | 2 +-
- src/lxc/mount_utils.c | 6 +++---
- src/lxc/syscall_wrappers.h | 12 ++++++++++--
- 5 files changed, 45 insertions(+), 11 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index a145faf069..f679aabbc8 100644
---- a/meson.build
-+++ b/meson.build
-@@ -590,7 +590,6 @@ decl_headers = '''
- foreach decl: [
- '__aligned_u64',
- 'struct clone_args',
-- 'struct mount_attr',
- 'struct open_how',
- 'struct rtnl_link_stats64',
- ]
-@@ -610,7 +609,6 @@ foreach tuple: [
- ['struct seccomp_notif_sizes'],
- ['struct clone_args'],
- ['__aligned_u64'],
-- ['struct mount_attr'],
- ['struct open_how'],
- ['struct rtnl_link_stats64'],
- ]
-@@ -630,6 +628,34 @@ foreach tuple: [
- endif
- endforeach
-
-+## Types.
-+decl_headers = '''
-+#include <sys/mount.h>
-+'''
-+
-+# We get -1 if the size cannot be determined
-+if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') > 0
-+ srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), true)
-+ found_types += 'struct mount_attr (sys/mount.h)'
-+else
-+ srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), false)
-+ missing_types += 'struct mount_attr (sys/mount.h)'
-+endif
-+
-+## Types.
-+decl_headers = '''
-+#include <linux/mount.h>
-+'''
-+
-+# We get -1 if the size cannot be determined
-+if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') > 0
-+ srcconf.set10('HAVE_UAPI_' + 'struct mount_attr'.underscorify().to_upper(), true)
-+ found_types += 'struct mount_attr (linux/mount.h)'
-+else
-+ srcconf.set10('HAVE_UAPI_' + 'struct mount_attr'.underscorify().to_upper(), false)
-+ missing_types += 'struct mount_attr (linux/mount.h)'
-+endif
-+
- ## Headers.
- foreach ident: [
- ['bpf', '''#include <sys/syscall.h>
-diff --git a/src/lxc/conf.c b/src/lxc/conf.c
-index ffbe74c2f6..4193cd07f5 100644
---- a/src/lxc/conf.c
-+++ b/src/lxc/conf.c
-@@ -2885,7 +2885,7 @@ static int __lxc_idmapped_mounts_child(struct lxc_handler *handler, FILE *f)
- struct lxc_mount_options opts = {};
- int dfd_from;
- const char *source_relative, *target_relative;
-- struct lxc_mount_attr attr = {};
-+ struct mount_attr attr = {};
-
- ret = parse_lxc_mount_attrs(&opts, mntent.mnt_opts);
- if (ret < 0)
-@@ -3005,7 +3005,7 @@ static int __lxc_idmapped_mounts_child(struct lxc_handler *handler, FILE *f)
-
- /* Set propagation mount options. */
- if (opts.attr.propagation) {
-- attr = (struct lxc_mount_attr) {
-+ attr = (struct mount_attr) {
- .propagation = opts.attr.propagation,
- };
-
-@@ -4109,7 +4109,7 @@ int lxc_idmapped_mounts_parent(struct lxc_handler *handler)
-
- for (;;) {
- __do_close int fd_from = -EBADF, fd_userns = -EBADF;
-- struct lxc_mount_attr attr = {};
-+ struct mount_attr attr = {};
- struct lxc_mount_options opts = {};
- ssize_t ret;
-
-diff --git a/src/lxc/conf.h b/src/lxc/conf.h
-index 7dc2f15b60..772479f9e1 100644
---- a/src/lxc/conf.h
-+++ b/src/lxc/conf.h
-@@ -223,7 +223,7 @@ struct lxc_mount_options {
- unsigned long mnt_flags;
- unsigned long prop_flags;
- char *data;
-- struct lxc_mount_attr attr;
-+ struct mount_attr attr;
- char *raw_options;
- };
-
-diff --git a/src/lxc/mount_utils.c b/src/lxc/mount_utils.c
-index bba75f933c..88dd73ee36 100644
---- a/src/lxc/mount_utils.c
-+++ b/src/lxc/mount_utils.c
-@@ -31,7 +31,7 @@ lxc_log_define(mount_utils, lxc);
- * setting in @attr_set, but must also specify MOUNT_ATTR__ATIME in the
- * @attr_clr field.
- */
--static inline void set_atime(struct lxc_mount_attr *attr)
-+static inline void set_atime(struct mount_attr *attr)
- {
- switch (attr->attr_set & MOUNT_ATTR__ATIME) {
- case MOUNT_ATTR_RELATIME:
-@@ -272,7 +272,7 @@ int create_detached_idmapped_mount(const char *path, int userns_fd,
- {
- __do_close int fd_tree_from = -EBADF;
- unsigned int open_tree_flags = OPEN_TREE_CLONE | OPEN_TREE_CLOEXEC;
-- struct lxc_mount_attr attr = {
-+ struct mount_attr attr = {
- .attr_set = MOUNT_ATTR_IDMAP | attr_set,
- .attr_clr = attr_clr,
- .userns_fd = userns_fd,
-@@ -335,7 +335,7 @@ int __fd_bind_mount(int dfd_from, const char *path_from, __u64 o_flags_from,
- __u64 attr_clr, __u64 propagation, int userns_fd,
- bool recursive)
- {
-- struct lxc_mount_attr attr = {
-+ struct mount_attr attr = {
- .attr_set = attr_set,
- .attr_clr = attr_clr,
- .propagation = propagation,
-diff --git a/src/lxc/syscall_wrappers.h b/src/lxc/syscall_wrappers.h
-index a5e98b565c..c8a7d0c7b7 100644
---- a/src/lxc/syscall_wrappers.h
-+++ b/src/lxc/syscall_wrappers.h
-@@ -18,6 +18,12 @@
- #include "macro.h"
- #include "syscall_numbers.h"
-
-+#if HAVE_STRUCT_MOUNT_ATTR
-+#include <sys/mount.h>
-+#elif HAVE_UAPI_STRUCT_MOUNT_ATTR
-+#include <linux/mount.h>
-+#endif
-+
- #ifdef HAVE_LINUX_MEMFD_H
- #include <linux/memfd.h>
- #endif
-@@ -210,16 +216,18 @@ extern int fsmount(int fs_fd, unsigned int flags, unsigned int attr_flags);
- /*
- * mount_setattr()
- */
--struct lxc_mount_attr {
-+#if !HAVE_STRUCT_MOUNT_ATTR && !HAVE_UAPI_STRUCT_MOUNT_ATTR
-+struct mount_attr {
- __u64 attr_set;
- __u64 attr_clr;
- __u64 propagation;
- __u64 userns_fd;
- };
-+#endif
-
- #if !HAVE_MOUNT_SETATTR
- static inline int mount_setattr(int dfd, const char *path, unsigned int flags,
-- struct lxc_mount_attr *attr, size_t size)
-+ struct mount_attr *attr, size_t size)
- {
- return syscall(__NR_mount_setattr, dfd, path, flags, attr, size);
- }
-
-From ef1e0607b82e27350c2d677d649c6a0a9693fd40 Mon Sep 17 00:00:00 2001
-From: Christian Brauner <brauner@kernel.org>
-Date: Tue, 9 Aug 2022 16:27:40 +0200
-Subject: [PATCH 2/3] build: detect sys/pidfd.h availability
-
-Fixes: #4176
-Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
----
- meson.build | 1 +
- src/lxc/process_utils.h | 6 ++++++
- 2 files changed, 7 insertions(+)
-
-diff --git a/meson.build b/meson.build
-index f679aabbc8..e999542336 100644
---- a/meson.build
-+++ b/meson.build
-@@ -735,6 +735,7 @@ foreach tuple: [
- ['sys/resource.h'],
- ['sys/memfd.h'],
- ['sys/personality.h'],
-+ ['sys/pidfd.h'],
- ['sys/signalfd.h'],
- ['sys/timerfd.h'],
- ['pty.h'],
-diff --git a/src/lxc/process_utils.h b/src/lxc/process_utils.h
-index 9c15b15741..ed84741d0e 100644
---- a/src/lxc/process_utils.h
-+++ b/src/lxc/process_utils.h
-@@ -15,6 +15,10 @@
- #include <sys/syscall.h>
- #include <unistd.h>
-
-+#if HAVE_SYS_PIDFD_H
-+#include <sys/pidfd.h>
-+#endif
-+
- #include "compiler.h"
- #include "syscall_numbers.h"
-
-@@ -136,9 +140,11 @@
- #endif
-
- /* waitid */
-+#if !HAVE_SYS_PIDFD_H
- #ifndef P_PIDFD
- #define P_PIDFD 3
- #endif
-+#endif
-
- #ifndef CLONE_ARGS_SIZE_VER0
- #define CLONE_ARGS_SIZE_VER0 64 /* sizeof first published struct */
-
-From cbabe8abf11e7e7fb49c123bae31efdd9bc8f1e8 Mon Sep 17 00:00:00 2001
-From: Christian Brauner <brauner@kernel.org>
-Date: Tue, 9 Aug 2022 17:19:40 +0200
-Subject: [PATCH 3/3] build: check for FS_CONFIG_* header symbol in sys/mount.h
-
-Fixes: #4176
-Signed-off-by: Christian Brauner (Microsoft) <christian.brauner@ubuntu.com>
----
- meson.build | 59 +++++++++++++++++++++++++++++++++++++++++--
- src/lxc/mount_utils.h | 16 ++++++++++++
- 2 files changed, 73 insertions(+), 2 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index e999542336..9f8a5de60c 100644
---- a/meson.build
-+++ b/meson.build
-@@ -639,8 +639,7 @@ if cc.sizeof('struct mount_attr', prefix: decl_headers, args: '-D_GNU_SOURCE') >
- found_types += 'struct mount_attr (sys/mount.h)'
- else
- srcconf.set10('HAVE_' + 'struct mount_attr'.underscorify().to_upper(), false)
-- missing_types += 'struct mount_attr (sys/mount.h)'
--endif
-+ missing_types += 'struct mount_attr (sys/mount.h)' endif
-
- ## Types.
- decl_headers = '''
-@@ -656,6 +655,62 @@ else
- missing_types += 'struct mount_attr (linux/mount.h)'
- endif
-
-+if cc.has_header_symbol('sys/mount.h', 'FSCONFIG_SET_FLAG')
-+ srcconf.set10('HAVE_' + 'FSCONFIG_SET_FLAG'.underscorify().to_upper(), true)
-+ found_types += 'FSCONFIG_SET_FLAG'
-+else
-+ srcconf.set10('HAVE_' + 'FSCONFIG_SET_FLAG'.underscorify().to_upper(), false)
-+ missing_types += 'FSCONFIG_SET_FLAG'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_STRING')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_STRING'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_STRING'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_STRING'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_STRING'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_BINARY')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_BINARY'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_BINARY'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_BINARY'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_BINARY'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_PATH_EMPTY')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_EMPTY'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_PATH_EMPTY'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_EMPTY'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_PATH_EMPTY'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_PATH_FD')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_FD'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_PATH_FD'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_PATH_FD'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_PATH_FD'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_CMD_CREATE')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_CREATE'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_CMD_CREATE'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_CREATE'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_CMD_CREATE'
-+endif
-+
-+if cc.has_header_symbol('sys/mount.h', 'FS_CONFIG_SET_CMD_RECONFIGURE')
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_RECONFIGURE'.underscorify().to_upper(), true)
-+ found_types += 'FS_CONFIG_SET_CMD_RECONFIGURE'
-+else
-+ srcconf.set10('HAVE_' + 'FS_CONFIG_SET_CMD_RECONFIGURE'.underscorify().to_upper(), false)
-+ missing_types += 'FS_CONFIG_SET_CMD_RECONFIGURE'
-+endif
-+
- ## Headers.
- foreach ident: [
- ['bpf', '''#include <sys/syscall.h>
-diff --git a/src/lxc/mount_utils.h b/src/lxc/mount_utils.h
-index ea392672d8..fd34739459 100644
---- a/src/lxc/mount_utils.h
-+++ b/src/lxc/mount_utils.h
-@@ -82,37 +82,53 @@ struct lxc_rootfs;
- #endif
-
- /* fsconfig() commands */
-+#if !HAVE_FSCONFIG_SET_FLAG
- #ifndef FSCONFIG_SET_FLAG
- #define FSCONFIG_SET_FLAG 0 /* Set parameter, supplying no value */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_SET_STRING
- #ifndef FSCONFIG_SET_STRING
- #define FSCONFIG_SET_STRING 1 /* Set parameter, supplying a string value */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_SET_BINARY
- #ifndef FSCONFIG_SET_BINARY
- #define FSCONFIG_SET_BINARY 2 /* Set parameter, supplying a binary blob value */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_SET_PATH
- #ifndef FSCONFIG_SET_PATH
- #define FSCONFIG_SET_PATH 3 /* Set parameter, supplying an object by path */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_SET_PATH_EMPTY
- #ifndef FSCONFIG_SET_PATH_EMPTY
- #define FSCONFIG_SET_PATH_EMPTY 4 /* Set parameter, supplying an object by (empty) path */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_SET_FD
- #ifndef FSCONFIG_SET_FD
- #define FSCONFIG_SET_FD 5 /* Set parameter, supplying an object by fd */
- #endif
-+#endif
-
-+#if !HAVE_FSCONFIG_CMD_CREATE
- #ifndef FSCONFIG_CMD_CREATE
- #define FSCONFIG_CMD_CREATE 6 /* Invoke superblock creation */
- #endif
-+#endif
-
-+#if !FSCONFIG_CMD_RECONFIGURE
- #ifndef FSCONFIG_CMD_RECONFIGURE
- #define FSCONFIG_CMD_RECONFIGURE 7 /* Invoke superblock reconfiguration */
- #endif
-+#endif
-
- /* fsmount() flags */
- #ifndef FSMOUNT_CLOEXEC
diff --git a/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch b/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch
deleted file mode 100644
index fe218ea0c3e6..000000000000
--- a/app-containers/lxc/files/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From b0abedf60b40adf0f2fb3cf9dfee4bc601f7b39f Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Thu, 25 Aug 2022 05:45:53 -0700
-Subject: [PATCH] use sd_bus_call_method_async to replace the asyncv one
-
-The sd_bus_call_method_asyncv's 10th parameter is of type
-va_list and supplying NULL when invoking it causes compilation
-error. Just replace it with the async one.
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build | 4 ++--
- src/lxc/cgroups/cgfsng.c | 2 +-
- 2 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index 21955a0504..f8bdcf4e83 100644
---- a/meson.build
-+++ b/meson.build
-@@ -295,9 +295,9 @@ if not want_sd_bus.disabled()
- has_sd_bus = false
- endif
-
-- if not cc.has_function('sd_bus_call_method_asyncv', prefix: '#include <systemd/sd-bus.h>', dependencies: libsystemd)
-+ if not cc.has_function('sd_bus_call_method_async', prefix: '#include <systemd/sd-bus.h>', dependencies: libsystemd)
- if not sd_bus_optional
-- error('libsystemd misses required sd_bus_call_method_asyncv function')
-+ error('libsystemd misses required sd_bus_call_method_async function')
- endif
-
- has_sd_bus = false
-diff --git a/src/lxc/cgroups/cgfsng.c b/src/lxc/cgroups/cgfsng.c
-index 8a3615893f..d90e5385e1 100644
---- a/src/lxc/cgroups/cgfsng.c
-+++ b/src/lxc/cgroups/cgfsng.c
-@@ -1232,7 +1232,7 @@ static int unpriv_systemd_create_scope(struct cgroup_ops *ops, struct lxc_conf *
- if (r < 0)
- return log_error(SYSTEMD_SCOPE_FAILED, "Failed to connect to user bus: %s", strerror(-r));
-
-- r = sd_bus_call_method_asyncv(bus, NULL, DESTINATION, PATH, INTERFACE, "Subscribe", NULL, NULL, NULL, NULL);
-+ r = sd_bus_call_method_async(bus, NULL, DESTINATION, PATH, INTERFACE, "Subscribe", NULL, NULL, NULL);
- if (r < 0)
- return log_error(SYSTEMD_SCOPE_FAILED, "Failed to subscribe to signals: %s", strerror(-r));
-
diff --git a/app-containers/lxc/lxc-5.0.1-r2.ebuild b/app-containers/lxc/lxc-5.0.1-r2.ebuild
deleted file mode 100644
index 5abe3f257413..000000000000
--- a/app-containers/lxc/lxc-5.0.1-r2.ebuild
+++ /dev/null
@@ -1,171 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 linux-info meson optfeature systemd toolchain-funcs verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P}.tar.gz.asc )"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
-IUSE="apparmor +caps examples io-uring lto man pam seccomp selinux ssl systemd test +tools"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- apparmor? ( sys-libs/libapparmor )
- caps? ( sys-libs/libcap[static-libs] )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? ( dev-libs/openssl:0= )
- systemd? ( sys-apps/systemd:= )
- tools? ( sys-libs/libcap[static-libs] )"
-DEPEND="${RDEPEND}
- sys-kernel/linux-headers"
-BDEPEND="virtual/pkgconfig
- man? ( app-text/docbook2X )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-RESTRICT="!test? ( test )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
-
-PATCHES=( "${FILESDIR}"/lxc-5.0.1-glibc-2.36.patch
- "${FILESDIR}"/lxc-5.0.1-use-sd_bus_call_method_async-insteaf-of-asyncv.patch )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-src_configure() {
- local emesonargs=(
- --localstatedir "${EPREFIX}/var"
-
- -Dcoverity-build=false
- -Doss-fuzz=false
-
- -Dcommands=true
- -Dmemfd-rexec=true
- -Dthread-safety=true
-
- $(meson_use apparmor)
- $(meson_use caps capabilities)
- $(meson_use examples)
- $(meson_use io-uring io-uring-event-loop)
- $(meson_use lto b_lto)
- $(meson_use man)
- $(meson_use pam pam-cgroup)
- $(meson_use seccomp)
- $(meson_use selinux)
- $(meson_use ssl openssl)
- $(meson_use test tests)
- $(meson_use tools)
-
- -Ddata-path=/var/lib/lxc
- -Ddoc-path=/usr/share/doc/${PF}
- -Dlog-path=/var/log/lxc
- -Drootfs-mount-path=/var/lib/lxc/rootfs
- -Druntime-path=/run
- )
-
- if use systemd; then
- local emesonargs+=( -Dinit-script="systemd" )
- local emesonargs+=( -Dsd-bus=enabled )
- else
- local emesonargs+=( -Dinit-script="sysvinit" )
- local emesonargs+=( -Dsd-bus=disabled )
- fi
-
- use tools && local emesonargs+=( -Dcapabilities=true )
-
- if $(tc-ld-is-gold) || $(tc-ld-is-lld); then
- local emesonargs+=( -Db_lto_mode=thin )
- else
- local emesonargs+=( -Db_lto_mode=default )
- fi
-
- meson_src_configure
-}
-
-src_install() {
- meson_src_install
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,autostart,cgroup,checkpoint,config,console,copy,create,destroy,device,execute,freeze,info,ls,monitor,snapshot,stop,top,unfreeze,unshare,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /var/lib/cache/lxc /var/lib/lib/lxc
-
- find "${ED}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Replace upstream sysvinit/systemd files.
- if use systemd; then
- rm -r "${D}$(systemd_get_systemunitdir)" || die "Failed to remove systemd lib dir"
- else
- rm "${ED}"/etc/init.d/lxc-{containers,net} || die "Failed to remove sysvinit scripts"
- fi
-
- newinitd "${FILESDIR}/${PN}.initd.8" ${PN}
- systemd_newunit "${FILESDIR}"/lxc-monitord.service.5.0.0 lxc-monitord.service
- systemd_newunit "${FILESDIR}"/lxc-net.service.5.0.0 lxc-net.service
- systemd_newunit "${FILESDIR}"/lxc.service-5.0.0 lxc.service
- systemd_newunit "${FILESDIR}"/lxc_at.service.5.0.0 "lxc@.service"
-
- if ! use apparmor; then
- sed -i '/lxc-apparmor-load/d' "${D}$(systemd_get_systemunitdir)/lxc.service" || die "Failed to remove apparmor references from lxc.service systemd unit."
- fi
-}
-
-pkg_postinst() {
- elog "Please refer to "
- elog "https://wiki.gentoo.org/wiki/LXC for introduction and usage guide."
- elog
- elog "Run 'lxc-checkconfig' to see optional kernel features."
- elog
-
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/
@ 2023-09-10 6:29 Joonas Niilola
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Niilola @ 2023-09-10 6:29 UTC (permalink / raw
To: gentoo-commits
commit: 4320b09b549e88a2a1cf5a287d3a3616ecc472eb
Author: Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 10 06:25:31 2023 +0000
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Sun Sep 10 06:25:31 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4320b09b
app-containers/lxc: drop 5.0.2
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
app-containers/lxc/Manifest | 2 -
app-containers/lxc/files/lxc.initd.8 | 131 ---------------------------
app-containers/lxc/lxc-5.0.2.ebuild | 168 -----------------------------------
3 files changed, 301 deletions(-)
diff --git a/app-containers/lxc/Manifest b/app-containers/lxc/Manifest
index 110ca14bf5ce..49be2b841cfd 100644
--- a/app-containers/lxc/Manifest
+++ b/app-containers/lxc/Manifest
@@ -1,4 +1,2 @@
-DIST lxc-5.0.2.tar.gz 973977 BLAKE2B e6017406b96f53525b576528814922a017a7d65fb04724046236307f4e85219b3c8ac725678e57ae3f77a4e817f718748e8c61fbc8147160e4ac87d3146b6567 SHA512 2e8800875e9c91cc0cbfdfc33c43d84bad9471d8a1b8ccd52d7d9c6fe44f280f9f701b8ccc2e0f5319a3e4c50d8c4331722f0dd9c0347575eb4f7b4ed110bef3
-DIST lxc-5.0.2.tar.gz.asc 833 BLAKE2B 3d78f8a87b2f45d2b91a9a6595d286e2fc1dcfc7d28f3c1d86e968860a7e346506ab28d4dafffede8acf1f82e8b12f90eda2e6210cd6bdec702f59bad97295c6 SHA512 9bd1ef117cf256841b75d409e8f14b88ed54fdfc9c8c472b6baa5e9695e39cdb8c1f47ce612dc8263abb65511df0812554cc9a5820cdd6c1539a07283a4cd08f
DIST lxc-5.0.3.tar.gz 975269 BLAKE2B 533d97fe4d986acbf5d562bb2c295a63df2a9a8bfc27aeff5056e4235f667102500debc586c5698482ec048c1b222a0fdc234db6fd6648c4b649f87a85de18f8 SHA512 0553be317431ab7ec0c450c0f85724a53de1f251c39c9716168e17cda6a8daec70b8221228c4be64027df28a327e0f1fd508e6bb48348ab540bbfeaf2b9ac974
DIST lxc-5.0.3.tar.gz.asc 833 BLAKE2B c35278ed17cad76d2ea94b3985e0110731efea751fb5f1c2d1c9db71486e4844285f372a94c8611dcfe91fdb16459694843b9e0a8273cfc68a56f549c7162cfb SHA512 a5ce5769d49abdf35d94de8273fd3e9c2a8ba4fafea71cf33ee6bce1d83531c8b550d972f7080409a4cc5a92e9d04ece50ed108f92c6aec4868d150e58d7d11a
diff --git a/app-containers/lxc/files/lxc.initd.8 b/app-containers/lxc/files/lxc.initd.8
deleted file mode 100644
index 727f6d504fb3..000000000000
--- a/app-containers/lxc/files/lxc.initd.8
+++ /dev/null
@@ -1,131 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-CONTAINER=${SVCNAME#*.}
-
-LXC_PATH=`lxc-config lxc.lxcpath`
-
-lxc_get_configfile() {
- if [ -f "${LXC_PATH}/${CONTAINER}.conf" ]; then
- echo "${LXC_PATH}/${CONTAINER}.conf"
- elif [ -f "${LXC_PATH}/${CONTAINER}/config" ]; then
- echo "${LXC_PATH}/${CONTAINER}/config"
- else
- eerror "Unable to find a suitable configuration file."
- eerror "If you set up the container in a non-standard"
- eerror "location, please set the CONFIGFILE variable."
- return 1
- fi
-}
-
-[ $CONTAINER != $SVCNAME ] && CONFIGFILE=${CONFIGFILE:-$(lxc_get_configfile)}
-
-lxc_get_var() {
- awk 'BEGIN { FS="[ \t]*=[ \t]*" } $1 == "'$1'" { print $2; exit }' ${CONFIGFILE}
-}
-
-lxc_get_net_link_type() {
- awk 'BEGIN { FS="[ \t]*=[ \t]*"; _link=""; _type="" }
- $1 == "lxc.network.type" {_type=$2;}
- $1 == "lxc.network.link" {_link=$2;}
- match($1, /lxc\.net\.[[:digit:]]+\.type/) {_type=$2;}
- match($1, /lxc\.net\.[[:digit:]]+\.link/) {_link=$2;}
- {if(_link != "" && _type != ""){
- printf("%s:%s\n", _link, _type );
- _link=""; _type="";
- }; }' <${CONFIGFILE}
-}
-
-checkconfig() {
- if [ ${CONTAINER} = ${SVCNAME} ]; then
- eerror "You have to create an init script for each container:"
- eerror " ln -s lxc /etc/init.d/lxc.container"
- return 1
- fi
-
- # no need to output anything, the function takes care of that.
- [ -z "${CONFIGFILE}" ] && return 1
-
- utsname=$(lxc_get_var lxc.uts.name)
- if [ -z "$utsname" ] ; then
- utsname=$(lxc_get_var lxc.utsname)
- fi
-
- if [ "${CONTAINER}" != "${utsname}" ]; then
- eerror "You should use the same name for the service and the"
- eerror "container. Right now the container is called ${utsname}"
- return 1
- fi
-}
-
-depend() {
- # be quiet, since we have to run depend() also for the
- # non-muxed init script, unfortunately.
- checkconfig 2>/dev/null || return 0
-
- config ${CONFIGFILE}
- need localmount
- use lxcfs
-
- local _x _if
- for _x in $(lxc_get_net_link_type); do
- _if=${_x%:*}
- case "${_x##*:}" in
- # when the network type is set to phys, we can make use of a
- # network service (for instance to set it up before we disable
- # the net_admin capability), but we might also not set it up
- # at all on the host and leave the net_admin capable service
- # to take care of it.
- phys) use net.${_if} ;;
- *) need net.${_if} ;;
- esac
- done
-}
-
-start() {
- checkconfig || return 1
- rm -f /var/log/lxc/${CONTAINER}.log
-
- rootpath=$(lxc_get_var lxc.rootfs)
-
- # Check the format of our init and the chroot's init, to see
- # if we have to use linux32 or linux64; always use setarch
- # when required, as that makes it easier to deal with
- # x32-based containers.
- case $(scanelf -BF '%a#f' ${rootpath}/sbin/init) in
- EM_X86_64) setarch=linux64;;
- EM_386) setarch=linux32;;
- esac
-
- ebegin "Starting LXC container ${CONTAINER}"
- env -i ${setarch} $(which lxc-start) -n ${CONTAINER} -f ${CONFIGFILE} -d -o /var/log/lxc/${CONTAINER}.log
- sleep 1
-
- # lxc-start -d will _always_ report a correct startup, even if it
- # failed, so rather than trust that, check that the cgroup exists.
- # fix for LXC 3.1
-
- STATE="$(lxc-info -s -H ${CONTAINER})"
- [ "$STATE" = "RUNNING" ]
-
- eend $?
-}
-
-stop() {
- checkconfig || return 1
-
- STATE="$(lxc-info -s -H ${CONTAINER})"
-
- if ! [ "$STATE" = "RUNNING" ]; then
- ewarn "${CONTAINER} doesn't seem to be started."
- return 0
- fi
-
- # 30s should be enough to shut everything down
- # lxc-stop will return back anyway as soon as successful shutdown
- # after 30s, lxc-stop sends SIGKILL (dirty shotdown)
- ebegin "Stopping LXC container ${CONTAINER}"
- lxc-stop -t 30 -n ${CONTAINER}
- eend $?
-}
diff --git a/app-containers/lxc/lxc-5.0.2.ebuild b/app-containers/lxc/lxc-5.0.2.ebuild
deleted file mode 100644
index de0e266a84c9..000000000000
--- a/app-containers/lxc/lxc-5.0.2.ebuild
+++ /dev/null
@@ -1,168 +0,0 @@
-# Copyright 2022-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit bash-completion-r1 linux-info meson optfeature systemd toolchain-funcs verify-sig
-
-DESCRIPTION="A userspace interface for the Linux kernel containment features"
-HOMEPAGE="https://linuxcontainers.org/ https://github.com/lxc/lxc"
-SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz
- verify-sig? ( https://linuxcontainers.org/downloads/lxc/${P}.tar.gz.asc )"
-
-LICENSE="GPL-2 LGPL-2.1 LGPL-3"
-SLOT="0/1.502" # SONAME liblxc.so.1 + ${PV//./} _if_ breaking ABI change while bumping.
-KEYWORDS="amd64 ~arm ~arm64 ~ppc64 ~riscv x86"
-IUSE="apparmor +caps examples io-uring lto man pam seccomp selinux ssl systemd test +tools"
-
-RDEPEND="acct-group/lxc
- acct-user/lxc
- apparmor? ( sys-libs/libapparmor )
- caps? ( sys-libs/libcap[static-libs] )
- io-uring? ( >=sys-libs/liburing-2:= )
- pam? ( sys-libs/pam )
- seccomp? ( sys-libs/libseccomp )
- selinux? ( sys-libs/libselinux )
- ssl? ( dev-libs/openssl:0= )
- systemd? ( sys-apps/systemd:= )
- tools? ( sys-libs/libcap[static-libs] )"
-DEPEND="${RDEPEND}
- sys-kernel/linux-headers"
-BDEPEND="virtual/pkgconfig
- man? ( app-text/docbook2X )
- verify-sig? ( sec-keys/openpgp-keys-linuxcontainers )"
-
-RESTRICT="!test? ( test )"
-
-CONFIG_CHECK="~!NETPRIO_CGROUP
- ~CGROUPS
- ~CGROUP_CPUACCT
- ~CGROUP_DEVICE
- ~CGROUP_FREEZER
-
- ~CGROUP_SCHED
- ~CPUSETS
- ~IPC_NS
- ~MACVLAN
-
- ~MEMCG
- ~NAMESPACES
- ~NET_NS
- ~PID_NS
-
- ~POSIX_MQUEUE
- ~USER_NS
- ~UTS_NS
- ~VETH"
-
-ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers"
-ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking"
-ERROR_MEMCG="CONFIG_MEMCG: needed for memory resource control in containers"
-ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network"
-ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command"
-ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info"
-ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking"
-
-VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/linuxcontainers.asc
-
-DOCS=( AUTHORS CONTRIBUTING MAINTAINERS README.md doc/FAQ.txt )
-
-pkg_setup() {
- linux-info_pkg_setup
-}
-
-src_configure() {
- local emesonargs=(
- --localstatedir "${EPREFIX}/var"
-
- -Dcoverity-build=false
- -Doss-fuzz=false
-
- -Dcommands=true
- -Dmemfd-rexec=true
- -Dthread-safety=true
-
- $(meson_use apparmor)
- $(meson_use caps capabilities)
- $(meson_use examples)
- $(meson_use io-uring io-uring-event-loop)
- $(meson_use lto b_lto)
- $(meson_use man)
- $(meson_use pam pam-cgroup)
- $(meson_use seccomp)
- $(meson_use selinux)
- $(meson_use ssl openssl)
- $(meson_use test tests)
- $(meson_use tools)
-
- -Ddata-path=/var/lib/lxc
- -Ddoc-path=/usr/share/doc/${PF}
- -Dlog-path=/var/log/lxc
- -Drootfs-mount-path=/var/lib/lxc/rootfs
- -Druntime-path=/run
- )
-
- if use systemd; then
- local emesonargs+=( -Dinit-script="systemd" )
- local emesonargs+=( -Dsd-bus=enabled )
- else
- local emesonargs+=( -Dinit-script="sysvinit" )
- local emesonargs+=( -Dsd-bus=disabled )
- fi
-
- use tools && local emesonargs+=( -Dcapabilities=true )
-
- if $(tc-ld-is-gold) || $(tc-ld-is-lld); then
- local emesonargs+=( -Db_lto_mode=thin )
- else
- local emesonargs+=( -Db_lto_mode=default )
- fi
-
- meson_src_configure
-}
-
-src_install() {
- meson_src_install
-
- # The main bash-completion file will collide with lxd, need to relocate and update symlinks.
- mkdir -p "${ED}"/$(get_bashcompdir) || die "Failed to create bashcompdir."
-
- if use tools; then
- bashcomp_alias lxc-start lxc-{attach,autostart,cgroup,checkpoint,config,console,copy,create,destroy,device,execute,freeze,info,ls,monitor,snapshot,stop,top,unfreeze,unshare,usernsexec,wait}
- else
- bashcomp_alias lxc-start lxc-usernsexec
- fi
-
- keepdir /var/lib/cache/lxc /var/lib/lib/lxc
-
- find "${ED}" -name '*.la' -delete -o -name '*.a' -delete || die
-
- # Replace upstream sysvinit/systemd files.
- if use systemd; then
- rm -r "${D}$(systemd_get_systemunitdir)" || die "Failed to remove systemd lib dir"
- else
- rm "${ED}"/etc/init.d/lxc-{containers,net} || die "Failed to remove sysvinit scripts"
- fi
-
- newinitd "${FILESDIR}/${PN}.initd.8" ${PN}
- systemd_newunit "${FILESDIR}"/lxc-monitord.service.5.0.0 lxc-monitord.service
- systemd_newunit "${FILESDIR}"/lxc-net.service.5.0.0 lxc-net.service
- systemd_newunit "${FILESDIR}"/lxc.service-5.0.0 lxc.service
- systemd_newunit "${FILESDIR}"/lxc_at.service.5.0.0 "lxc@.service"
-
- if ! use apparmor; then
- sed -i '/lxc-apparmor-load/d' "${D}$(systemd_get_systemunitdir)/lxc.service" || die "Failed to remove apparmor references from lxc.service systemd unit."
- fi
-}
-
-pkg_postinst() {
- elog "Please refer to "
- elog "https://wiki.gentoo.org/wiki/LXC for introduction and usage guide."
- elog
- elog "Run 'lxc-checkconfig' to see optional kernel features."
- elog
-
- optfeature "automatic template scripts" app-containers/lxc-templates
- optfeature "Debian-based distribution container image support" dev-util/debootstrap
- optfeature "snapshot & restore functionality" sys-process/criu
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2023-09-10 6:29 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-22 7:14 [gentoo-commits] repo/gentoo:master commit in: app-containers/lxc/, app-containers/lxc/files/ Joonas Niilola
-- strict thread matches above, loose matches on Subject: below --
2023-09-10 6:29 Joonas Niilola
2022-10-06 11:13 Joonas Niilola
2022-10-04 16:10 Joonas Niilola
2022-09-10 5:24 Joonas Niilola
2022-08-16 7:55 Joonas Niilola
2022-04-14 11:51 Joonas Niilola
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox