libcamera: Fix build with gcc-15
PATCH 1/1 libcamera: Fix build with gcc-15
From: "tho3.nguyen" <[email protected]>
To fix the following error:
...
In file included from ../git/src/libcamera/dma_buf_allocator.cpp:9:../git/include/libcamera/internal/dma_buf_allocator.h:66:19: error: 'uint64_t' has not been declared
66 | void sync(uint64_t step);
| ^~~~~~~~../git/include/libcamera/internal/dma_buf_allocator.h:17:1: note: 'uint64_t' is defined in header '<cstdint>'; this is probably fixable by adding '#include <cstdint>'
...
Signed-off-by tho3.nguyen <[email protected]>
--- ...uf_allocator.h-Fix-build-with-gcc-15.patch | 36 +++++++++++++++++++ .../libcamera/libcamera_0.4.0.bb | 1 + 2 files changed, 37 insertions(+) create mode 100644 meta-multimedia/recipes-multimedia/libcamera/libcamera/0002-dma_buf_allocator.h-Fix-build-with-gcc-15.patch
meta-multimedia/recipes-multimedia/libcamera/libcamera/0002-dma_buf_allocator.h-Fix-build-with-gcc-15.patch new file +36 -0
@@ -0,0 +1,36 @@ +From cc890633721df67f362e72eb7d099cc04f47982d Mon Sep 17 00:00:00 2001 +From: "tho3.nguyen" <[email protected]> +Date: Fri, 28 Mar 2025 13:20:56 +0900 +Subject: [PATCH] dma_buf_allocator.h: Fix build with gcc-15 + +To fix: +... +In file included from ../git/src/libcamera/dma_buf_allocator.cpp:9: +../git/include/libcamera/internal/dma_buf_allocator.h:66:19: error: 'uint64_t' has not been declared + 66 | void sync(uint64_t step); + | ^~~~~~~~ +../git/include/libcamera/internal/dma_buf_allocator.h:17:1: note: 'uint64_t' is defined in header '<cstdint>'; this is probably fixable by adding '#include <cstdint>' +... + +Upstream-Status: Submitted [https://patchwork.libcamera.org/patch/23066/] + +Signed-off-by: tho3.nguyen <[email protected]> +--- + include/libcamera/internal/dma_buf_allocator.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/include/libcamera/internal/dma_buf_allocator.h b/include/libcamera/internal/dma_buf_allocator.h +index fc5de2c1..973aec47 100644 +--- a/include/libcamera/internal/dma_buf_allocator.h ++++ b/include/libcamera/internal/dma_buf_allocator.h +@@ -10,6 +10,7 @@ + #include <memory> + #include <string> + #include <vector> ++#include <cstdint> + + #include <libcamera/base/flags.h> + #include <libcamera/base/shared_fd.h> +-- +2.34.1 +
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.4.0.bb +1 -0
@@ -11,6 +11,7 @@ LIC_FILES_CHKSUM = "\ SRC_URI = " \ git://git.libcamera.org/libcamera/libcamera.git;protocol=https;branch=master \ file://0001-media_device-Add-bool-return-type-to-unlock.patch \ + file://0002-dma_buf_allocator.h-Fix-build-with-gcc-15.patch \ " SRCREV = "35ed4b91291d9f3d08e4b51acfb51163e65df8f8"
Signature · 1 line
2.34.1