commit: 36394d5d275fadd5f4d19be32f6ab1214defc465 Author: James Le Cuirot <chewi <AT> gentoo <DOT> org> AuthorDate: Wed Aug 6 20:31:56 2025 +0000 Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org> CommitDate: Wed Aug 6 20:35:04 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=36394d5d
media-libs/libv4l: Fix building with libc++ 21 using patch This has been submitted upstream. Closes: https://bugs.gentoo.org/960750 Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org> .../files/libv4l-1.30.1-cpp-fallthrough.patch | 29 ++++++++++++++++++++++ media-libs/libv4l/libv4l-1.30.1.ebuild | 4 +++ 2 files changed, 33 insertions(+) diff --git a/media-libs/libv4l/files/libv4l-1.30.1-cpp-fallthrough.patch b/media-libs/libv4l/files/libv4l-1.30.1-cpp-fallthrough.patch new file mode 100644 index 000000000000..7e403ab0e6cb --- /dev/null +++ b/media-libs/libv4l/files/libv4l-1.30.1-cpp-fallthrough.patch @@ -0,0 +1,29 @@ +From f431bb813df169858540b8a819cedeb1805515c9 Mon Sep 17 00:00:00 2001 +From: James Le Cuirot <[email protected]> +Date: Sun, 3 Aug 2025 23:42:08 +0100 +Subject: [PATCH] compiler.h: Fix libc++ build now that _LIBCPP_FALLTHROUGH has + gone + +This has been dropped in favour of [[__fallthrough__]]. + +https://github.com/llvm/llvm-project/commit/cb43fe33b5d5084cf3b5a2723a03b692edb68018 + +Signed-off-by: James Le Cuirot <[email protected]> +--- a/include/compiler.h ++++ b/include/compiler.h +@@ -3,7 +3,11 @@ + #else + #include <ciso646> + #ifdef _LIBCPP_VERSION +- #define fallthrough _LIBCPP_FALLTHROUGH() ++ #ifdef _LIBCPP_FALLTHROUGH ++ #define fallthrough _LIBCPP_FALLTHROUGH() ++ #else ++ #define fallthrough [[__fallthrough__]] ++ #endif // _LIBCPP_FALLTHROUGH + #else + #ifdef __clang__ + #define fallthrough [[clang::fallthrough]] +-- +2.50.1 + diff --git a/media-libs/libv4l/libv4l-1.30.1.ebuild b/media-libs/libv4l/libv4l-1.30.1.ebuild index b0ec46de16ef..f98c0f5575bd 100644 --- a/media-libs/libv4l/libv4l-1.30.1.ebuild +++ b/media-libs/libv4l/libv4l-1.30.1.ebuild @@ -63,6 +63,10 @@ BDEPEND=" ) " +PATCHES=( + "${FILESDIR}"/${P}-cpp-fallthrough.patch +) + # Not really prebuilt but BPF objects make our QA checks go crazy. QA_PREBUILT="*/rc_keymaps/protocols/*.o"
