commit:     5f696cf69f7580b3b3e4483e58437a5e29400a25
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sun Jul 25 22:57:07 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Jul 25 23:23:32 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5f696cf6

media-video/bino: update EAPI 6 -> 7, fix build with GCC 11

Closes: https://bugs.gentoo.org/790128
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-video/bino/bino-1.6.7.ebuild            | 43 +++++++++++----------------
 media-video/bino/files/bino-1.6.7-gcc11.patch | 30 +++++++++++++++++++
 2 files changed, 48 insertions(+), 25 deletions(-)

diff --git a/media-video/bino/bino-1.6.7.ebuild 
b/media-video/bino/bino-1.6.7.ebuild
index 2969055aea7..8c5b35e1714 100644
--- a/media-video/bino/bino-1.6.7.ebuild
+++ b/media-video/bino/bino-1.6.7.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
+EAPI=7
 
-inherit flag-o-matic xdg-utils
+inherit flag-o-matic xdg
 
 DESCRIPTION="Stereoscopic and multi-display media player"
 HOMEPAGE="https://bino3d.org/";
@@ -25,28 +25,28 @@ RDEPEND="
        virtual/libintl
        >=media-video/ffmpeg-0.7:0=
        lirc? ( app-misc/lirc )
-       video_cards_nvidia? ( x11-drivers/nvidia-drivers[tools,static-libs] )
-"
-DEPEND="${RDEPEND}
-       sys-devel/gettext
-       virtual/pkgconfig
-"
+       video_cards_nvidia? ( x11-drivers/nvidia-drivers[tools,static-libs] )"
+DEPEND="${RDEPEND}"
+BDEPEND="sys-devel/gettext
+       virtual/pkgconfig"
 
-src_configure() {
-       # Qt5 now requires C++11, #649282
-       append-cxxflags -std=c++11
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.6.7-gcc11.patch
+)
 
+src_configure() {
        if use video_cards_nvidia; then
-               append-cppflags "-I/usr/include/NVCtrl"
-               append-ldflags "-L/usr/$(get_libdir)/opengl/nvidia/lib 
-L/usr/$(get_libdir)"
+               append-cppflags "-I${ESYSROOT}/usr/include/NVCtrl"
+               append-ldflags 
"-L${ESYSROOT}/usr/$(get_libdir)/opengl/nvidia/lib 
-L${ESYSROOT}/usr/$(get_libdir)"
                append-libs "Xext"
        fi
+
        if use lirc; then
-               append-cppflags "-I/usr/include/lirc"
+               append-cppflags "-I${ESYSROOT}/usr/include/lirc"
                append-libs "lirc_client"
        fi
 
-       # Fix a compilation error because of a multiple definitions in glew
+       # Fix a compilation error because of a multiple definitions error in 
glew
        append-ldflags "-zmuldefs"
 
        econf \
@@ -59,15 +59,8 @@ src_configure() {
 
 src_install() {
        default
+
        if ! use doc; then
-               rm -rf "${D}"/usr/share/doc/${PF}/html || die
+               rm -rf "${ED}"/usr/share/doc/${PF}/html || die
        fi
 }
-
-pkg_postinst() {
-       xdg_desktop_database_update
-}
-
-pkg_postrm() {
-       xdg_desktop_database_update
-}

diff --git a/media-video/bino/files/bino-1.6.7-gcc11.patch 
b/media-video/bino/files/bino-1.6.7-gcc11.patch
new file mode 100644
index 00000000000..8d4bf4070f3
--- /dev/null
+++ b/media-video/bino/files/bino-1.6.7-gcc11.patch
@@ -0,0 +1,30 @@
+https://git.marlam.de/gitweb/?p=bino.git;a=commitdiff;h=7997ad11eefe241bb85a27c50d009c99851d7b0b
+https://bugs.gentoo.org/790128
+
+From 7997ad11eefe241bb85a27c50d009c99851d7b0b Mon Sep 17 00:00:00 2001
+From: Martin Lambers <[email protected]>
+Date: Sat, 27 Feb 2021 21:28:50 +0100
+Subject: [PATCH] fix compilation with C++ 17 compilers such as gcc 11
+
+---
+ src/base/dbg.cpp | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/base/dbg.cpp b/src/base/dbg.cpp
+index 6c6234f..044be67 100644
+--- a/src/base/dbg.cpp
++++ b/src/base/dbg.cpp
+@@ -74,8 +74,10 @@ namespace dbg
+         (void)sigaction(SIGFPE, &signal_handler, NULL);
+         (void)sigaction(SIGSEGV, &signal_handler, NULL);
+ #endif
++#if __cplusplus < 201700
+         std::set_unexpected(exception_crash);
+         std::set_terminate(exception_crash);
++#endif
+         std::set_new_handler(oom_abort);
+     }
+ 
+-- 
+2.20.1
+

Reply via email to