commit:     9c19562ac6472473a6003b37816c33386db7fa23
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 25 16:07:21 2022 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Fri Feb 25 16:08:56 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9c19562a

media-sound/mumble: Added dev-cpp/nlohmann_json to DEPEND in live ebuild

Bug: https://bugs.gentoo.org/834030
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 media-sound/mumble/files/mumble-9999-system_json.patch | 18 ++++++++++++++++++
 media-sound/mumble/mumble-9999.ebuild                  |  5 +++++
 2 files changed, 23 insertions(+)

diff --git a/media-sound/mumble/files/mumble-9999-system_json.patch 
b/media-sound/mumble/files/mumble-9999-system_json.patch
new file mode 100644
index 000000000000..2be7553d50ef
--- /dev/null
+++ b/media-sound/mumble/files/mumble-9999-system_json.patch
@@ -0,0 +1,18 @@
+diff --git a/src/mumble/CMakeLists.txt b/src/mumble/CMakeLists.txt
+index bb8df1671..51f83850e 100644
+--- a/src/mumble/CMakeLists.txt
++++ b/src/mumble/CMakeLists.txt
+@@ -472,12 +472,7 @@ else()
+ endif()
+ 
+ 
+-set(JSON_BuildTests OFF CACHE INTERNAL "")
+-set(JSON_ImplicitConversions OFF CACHE INTERNAL "")
+-add_subdirectory("${3RDPARTY_DIR}/nlohmann_json/" 
"${CMAKE_CURRENT_BINARY_DIR}/nlohmann_json/")
+-
+-target_link_libraries(mumble_client_object_lib PUBLIC 
nlohmann_json::nlohmann_json)
+-
++find_pkg("nlohmann_json" REQUIRED)
+ find_pkg("SndFile;LibSndFile;sndfile" REQUIRED)
+ 
+ # Check if sndfile version supports opus

diff --git a/media-sound/mumble/mumble-9999.ebuild 
b/media-sound/mumble/mumble-9999.ebuild
index 0f0d04d692c3..a5cfa6d410b7 100644
--- a/media-sound/mumble/mumble-9999.ebuild
+++ b/media-sound/mumble/mumble-9999.ebuild
@@ -57,6 +57,7 @@ RDEPEND="
        zeroconf? ( net-dns/avahi[mdnsresponder-compat] )
 "
 DEPEND="${RDEPEND}
+       dev-cpp/nlohmann_json
        dev-qt/qtconcurrent:5
        dev-qt/qttest:5
        >=dev-libs/boost-1.41.0
@@ -70,6 +71,10 @@ BDEPEND="
 src_prepare() {
        sed '/TRACY_ON_DEMAND/s@ ON @ OFF @' -i src/CMakeLists.txt || die
 
+       if [[ "${PV}" == *9999 ]] ; then
+               PATCHES+=( "${FILESDIR}/${P}-system_json.patch" )
+       fi
+
        # required because of xdg.eclass also providing src_prepare
        cmake_src_prepare
 }

Reply via email to