lxcfs: fix build with newer linux-libc-headers
PATCH 1/2 lxcfs: fix build with newer linux-libc-headers
--- ...-build-with-newer-linux-libc-headers.patch | 50 +++++++++++++++++++ recipes-containers/lxcfs/lxcfs_4.0.7.bb | 1 + 2 files changed, 51 insertions(+) create mode 100644 recipes-containers/lxcfs/lxcfs/0001-bindings-fix-build-with-newer-linux-libc-headers.patch
recipes-containers/lxcfs/lxcfs/0001-bindings-fix-build-with-newer-linux-libc-headers.patch new file +50 -0
@@ -0,0 +1,50 @@ +From ca3c3484b078304998b3f2a2d6cd6c00540deb2c Mon Sep 17 00:00:00 2001 +From: Martin Jansa <[email protected]> +Date: Fri, 28 Apr 2023 19:16:11 +0000 +Subject: [PATCH] bindings: fix build with newer linux-libc-headers + +Fixes: + +../../lxcfs-4.0.7/src/bindings.c: In function 'initpid_still_valid_pidfd': +../../lxcfs-4.0.7/src/bindings.c:160:15: error: implicit declaration of function 'pidfd_send_signal'; did you mean 'SYS_pidfd_send_signal'? [-Werr +or=implicit-function-declaration] + 160 | ret = pidfd_send_signal(entry->init_pidfd, 0, NULL, 0); + | ^~~~~~~~~~~~~~~~~ + | SYS_pidfd_send_signal +../../lxcfs-4.0.7/src/bindings.c:160:15: warning: nested extern declaration of 'pidfd_send_signal' [-Wnested-externs] +../../lxcfs-4.0.7/src/bindings.c: In function 'save_initpid': +../../lxcfs-4.0.7/src/bindings.c:296:25: error: implicit declaration of function 'pidfd_open' [-Werror=implicit-function-declaration] + 296 | pidfd = pidfd_open(pid, 0); + | ^~~~~~~~~~ +../../lxcfs-4.0.7/src/bindings.c:296:25: warning: nested extern declaration of 'pidfd_open' [-Wnested-externs] +../../lxcfs-4.0.7/src/bindings.c: At top level: +../../lxcfs-4.0.7/src/bindings.c:612:12: warning: function declaration isn't a prototype [-Wstrict-prototypes] + 612 | static int pivot_enter() + | ^~~~~~~~~~~ +../../lxcfs-4.0.7/src/bindings.c: In function 'pivot_enter': +../../lxcfs-4.0.7/src/bindings.c:612:12: warning: old-style function definition [-Wold-style-definition] +../../lxcfs-4.0.7/src/bindings.c: At top level: +../../lxcfs-4.0.7/src/bindings.c:655:12: warning: function declaration isn't a prototype [-Wstrict-prototypes] + 655 | static int chroot_enter() + | ^~~~~~~~~~~~ +../../lxcfs-4.0.7/src/bindings.c: In function 'chroot_enter': +../../lxcfs-4.0.7/src/bindings.c:655:12: warning: old-style function definition [-Wold-style-definition] + +Signed-off-by: Martin Jansa <[email protected]> +Upstream-Status: Pending +--- + src/bindings.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/bindings.c b/src/bindings.c +index 6f2444c..3e0d60a 100644 +--- a/src/bindings.c ++++ b/src/bindings.c +@@ -39,6 +39,7 @@ + #include <sys/mman.h> + #include <sys/mount.h> + #include <sys/param.h> ++#include <sys/pidfd.h> + #include <sys/socket.h> + #include <sys/syscall.h> + #include <sys/sysinfo.h>
recipes-containers/lxcfs/lxcfs_4.0.7.bb +1 -0
@@ -7,6 +7,7 @@ SRC_URI = " \ https://linuxcontainers.org/downloads/lxcfs/lxcfs-${PV}.tar.gz \ file://systemd-allow-for-distinct-build-directory.patch \ file://systemd-ensure-var-lib-lxcfs-exists.patch \ + file://0001-bindings-fix-build-with-newer-linux-libc-headers.patch \ " LIC_FILES_CHKSUM = "file://COPYING;md5=29ae50a788f33f663405488bc61eecb1"
Signature · 1 line
2.40.1
PATCH 2/2 ceph: fix build with gcc-13
* this isn't complete fix as there are still issues from new boost as in:
https://github.com/boostorg/phoenix/issues/111
http://errors.yoctoproject.org/Errors/Details/702743/
TOPDIR/tmp-glibc/work/core2-64-oe-linux/ceph/15.2.15-r0/recipe-sysroot-native/usr/bin/x86_64-oe-linux/../../libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/13.1.0/ld: CMakeFiles/common-objs.dir/mon/MonCap.cc.o:/usr/include/boost/preprocessor/iteration/detail/limits/local_256.hpp:43: multiple definition of `boost::phoenix::placeholders::uarg10'; common/CMakeFiles/common-common-objs.dir/ConfUtils.cc.o:/usr/include/boost/preprocessor/iteration/detail/limits/local_256.hpp:43: first defined here
* probably easiest fix for above would be to upgrade to newer ceph, but I'm not using it, so couldn't properly test it (I was just looking at bitbake world failures in mickledore
--- ...-with-GCC-13-missing-cstdint-include.patch | 41 +++++++ ...itVector-NoInitAllocator-with-wrappe.patch | 101 ++++++++++++++++++ .../0003-librdb-fix-build-with-gcc-13.patch | 30 ++++++ recipes-extended/ceph/ceph_15.2.15.bb | 3 + 4 files changed, 175 insertions(+) create mode 100644 recipes-extended/ceph/ceph/0001-common-fix-build-with-GCC-13-missing-cstdint-include.patch create mode 100644 recipes-extended/ceph/ceph/0002-common-replace-BitVector-NoInitAllocator-with-wrappe.patch create mode 100644 recipes-extended/ceph/ceph/0003-librdb-fix-build-with-gcc-13.patch
recipes-extended/ceph/ceph/0001-common-fix-build-with-GCC-13-missing-cstdint-include.patch new file +41 -0
@@ -0,0 +1,41 @@ +From 59e6b44f7ed4020a860e347322acfdacc6e4560b Mon Sep 17 00:00:00 2001 +From: Sam James <[email protected]> +Date: Fri, 28 Oct 2022 16:47:38 +0100 +Subject: [PATCH] common: fix build with GCC 13 (missing <cstdint> include) +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Needed for uint8_t. Only worked by chance before (see +https://www.gnu.org/software/gcc/gcc-13/porting_to.html). + +``` +FAILED: src/CMakeFiles/common-objs.dir/mds/FSMapUser.cc.o +/usr/bin/x86_64-pc-linux-gnu-g++ -DBOOST_ASIO_DISABLE_THREAD_KEYWORD_EXTENSION -DHAVE_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_REENTRANT -D_THREAD_SAFE -D__CEPH__ -D__STDC_FORMAT_MACROS -D__linux__ -I/var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5_build/src/include -I/var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src -isystem /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5_build/include -isystem /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/xxHash -isystem /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/rapidjson/include -O2 -march=native -pipe -fPIC -U_FORTIFY_SOURCE -Wall -fno-strict-aliasing -fsigned-char -Wtype-limits -Wignored-qualifiers -Wpointer-arith -Werror=format-security -Winit-self -Wno-unknown-pragmas -Wnon-virtual-dtor -Wno-ignored-qualifiers -ftemplate-depth-1024 -Wpessimizing-move -Wredundant-move -Wstrict-null-sentinel -Woverloaded-virtual -fno-new-ttp-matching -fstack-protector-strong -fdiagnostics-color=auto -fno-builtin-malloc -fno-builtin-calloc -fno-builtin-realloc -fno-builtin-free -std=c++17 -MD -MT src/CMakeFiles/common-objs.dir/mds/FSMapUser.cc.o -MF src/CMakeFiles/common-objs.dir/mds/FSMapUser.cc.o.d -o src/CMakeFiles/common-objs.dir/mds/FSMapUser.cc.o -c /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/mds/FSMapUser.cc +In file included from /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/log/SubsystemMap.h:12, + from /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/common/config.h:23, + from /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/mds/mdstypes.h:13, + from /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/mds/FSMapUser.h:21, + from /var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/mds/FSMapUser.cc:1: +/var/tmp/portage/sys-cluster/ceph-17.2.5/work/ceph-17.2.5/src/common/subsys_types.h:56:23: error: ‘uint8_t’ in namespace ‘std’ does not name a type; did you mean ‘wint_t’? +``` + +Bug: https://bugs.gentoo.org/878531 +Signed-off-by: Sam James <[email protected]> +Upstream-Status: Backport [https://github.com/ceph/ceph/commit/74794f9d6f5c6671438085bdba730b504901a7c0] +--- + src/common/subsys_types.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/common/subsys_types.h b/src/common/subsys_types.h +index 52171809..bd7cc439 100644 +--- a/src/common/subsys_types.h ++++ b/src/common/subsys_types.h +@@ -17,6 +17,7 @@ + + #include <algorithm> + #include <array> ++#include <cstdint> + + enum ceph_subsys_id_t { + ceph_subsys_, // default
recipes-extended/ceph/ceph/0002-common-replace-BitVector-NoInitAllocator-with-wrappe.patch new file +101 -0
101 lines not on this page · raw message
recipes-extended/ceph/ceph/0003-librdb-fix-build-with-gcc-13.patch new file +30 -0
@@ -0,0 +1,30 @@ +From 937231991bd7e2cd578cf8cb6c1bedf611c5faef Mon Sep 17 00:00:00 2001 +From: Martin Jansa <[email protected]> +Date: Sat, 29 Apr 2023 13:47:43 +0200 +Subject: [PATCH] librdb: fix build with gcc-13 + +* fixes: +ceph-15.2.15/src/librbd/api/PoolMetadata.h:28:19: error: 'uint64_t' has not bee +n declared +ceph/15.2.15-r0/ceph-15.2.15/src/librbd/api/PoolMetadata.cc:133:5: error: no declaration matche +s 'int librbd::api::PoolMetadata<ImageCtxT>::list(librados::v14_2_0::IoCtx&, const std::string&, uint64_t, std::map<std::__cxx11::basic_string<cha +r>, ceph::buffer::v15_2_0::list>*)' + +Signed-off-by: Martin Jansa <[email protected]> +Upstream-Status: Pending +--- + src/librbd/api/PoolMetadata.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/librbd/api/PoolMetadata.h b/src/librbd/api/PoolMetadata.h +index c0a81735..69ab574a 100644 +--- a/src/librbd/api/PoolMetadata.h ++++ b/src/librbd/api/PoolMetadata.h +@@ -7,6 +7,7 @@ + #include "include/buffer_fwd.h" + #include "include/rados/librados_fwd.hpp" + ++#include <cstdint> + #include <map> + #include <string> +
recipes-extended/ceph/ceph_15.2.15.bb +3 -0
@@ -23,6 +23,9 @@ SRC_URI = "http://download.ceph.com/tarballs/ceph-${PV}.tar.gz \ file://0004-kv-rocksdb_cache-implement-methods-required-by-rocks.patch \ file://0005-kv-rocksdb_cache-mark-Shard-const.patch \ file://0006-rocksdb-build-with-rocksdb-7.y.z.patch \ + file://0001-common-fix-build-with-GCC-13-missing-cstdint-include.patch \ + file://0002-common-replace-BitVector-NoInitAllocator-with-wrappe.patch \ + file://0003-librdb-fix-build-with-gcc-13.patch \ " SRC_URI[sha256sum] = "5dccdaff2ebe18d435b32bfc06f8b5f474bf6ac0432a6a07d144b7c56700d0bf"
Signature · 1 line
2.40.1