games-util/mangohud: 9999: Update deps

- python 3.14 compat
- imgui 1.91.6
- vulkan headers 1.3.283-1
- use new github wrapdb SRC_URI
- partial revert of d868674 to continue using system imgui
- replace imgui sed statements with patch file

Signed-off-by: Erica Nebula <EricaNebula@Proton.me>
This commit is contained in:
Erica Nebula
2026-01-15 14:09:28 -06:00
parent d09a94457f
commit 41b91ff5a0
3 changed files with 147 additions and 17 deletions

View File

@@ -4,3 +4,5 @@ DIST mangohud-0.8.1.tar.gz 14918082 BLAKE2B 11ca387718b13f853573e37212bbd838c915
DIST mangohud-0.8.2.tar.gz 14934235 BLAKE2B 2fbf57fb4b68ba808f8b99cbdf0606a618e993695c938a45a8abc04dff29f00823f3a0858850e1f52e14615b7d40775fcf0ae3fcd8b48fe7cf578237caae8930 SHA512 9f5a04a01a0a28569c44b57ea59dc17f98a418afd93680e616d208e33b31bb57d081d479239b172b2ebc83f5872b187726324fe76b504dc43169057943bba637
DIST vulkan-headers-1.2.158-2-meson-wrap.zip 1107 BLAKE2B 35e4bb1f7410a009243fe7d4a4ba6cede7f01e0b56ad6ff72ad30c00c2452bd6d2a4fb44ab92c296147e2506a92acc6de1f817cb5433b96d66652cbcd8885595 SHA512 30cbbb90580399839e1bba8881b9b8cc33fdeead93f37d5f3398c9d53fb3ab050ca2562fd68f376fa4ee0825ee3787f560d70d55a170c780dd575ff2eeb66efd
DIST vulkan-headers-1.2.158.tar.gz 831647 BLAKE2B 792d7e895e27c4a8fbc93fc4d9c9e696d2ceb946e745709c050c0693b77afbeb6411a4267fc59508ddeb58167d469349fedc1c5d4b4a7415b590c97248b244bc SHA512 f7aa9222f9deb1316d22deacc2c6cd85c409f0f2b2d37ecd55e0fc8466d381bbe3bed287881b993a01c5f33736e1607014f820980b7a54a3721fab6980960c91
DIST vulkan-headers-1.3.283-1-meson-wrap.zip 1219 BLAKE2B 48efb687335a478e16396114d13177b91aba5b4fd321d155d028c404d39d4968a74b3911bbfcfebd6288bc922f52e4b761ee348df4d772a45e57a60d302e5641 SHA512 45aab78ea50b280610bdb6ba704388a16f159ddab1d19ae503e58edaee403f979027a18bf0303780e63e63d807368d1911388a5b5c2da42bb5ca89b5d8d47d85
DIST vulkan-headers-1.3.283.tar.gz 2271437 BLAKE2B 641baef95972c88ba1e5369b3522db3db223f1191e423e7d8938d20d132276ade8afc6611efad25a1cf0434a7a0bada6a52ac0a74af809cde96e55ec6b06671d SHA512 48a863b8b9c9131c65253071e3b45fc35b98db241d2a1737969f5ae9a4d0a7e0fda37c7fe8f956fec549fcde4999b038faaede7e54066076386bad2794d311f8

View File

@@ -0,0 +1,134 @@
diff --git a/meson.build b/meson.build
index 1146a26..9634dc0 100644
--- a/meson.build
+++ b/meson.build
@@ -253,13 +253,14 @@ if get_option('mangoapp')
]
endif
-imgui_sp = subproject('imgui', default_options: imgui_options)
-dearimgui_dep = imgui_sp.get_variable('imgui_dep')
+dearimgui_dep = dependency('imgui', fallback: ['imgui'], required: true, default_options: imgui_options)
-meson.override_dependency('imgui', dearimgui_dep)
-
-implot_sp = subproject('implot', default_options: ['default_library=static'])
-implot_dep = implot_sp.get_variable('implot_dep')
+if is_unixy
+ implot_dep = dependency('implot', fallback: ['implot'], required: true, default_options: ['default_library=static'])
+else
+ implot_dep = null_dep
+ implot_lib = static_library('nulllib', [])
+endif
spdlog_options = [
'default_library=static',
diff --git a/src/app/main.cpp b/src/app/main.cpp
index 2235476..0d457c8 100644
--- a/src/app/main.cpp
+++ b/src/app/main.cpp
@@ -6,9 +6,9 @@
#include <sys/ipc.h>
#include <sys/msg.h>
-#include "imgui.h"
-#include "imgui_impl_glfw.h"
-#include "imgui_impl_opengl3.h"
+#include <imgui/imgui.h>
+#include <imgui/imgui_impl_glfw.h>
+#include <imgui/imgui_impl_opengl3.h>
#include <stdio.h>
#include <thread>
#include <unistd.h>
diff --git a/src/gl/gl_hud.cpp b/src/gl/gl_hud.cpp
index 2ef688d..c47cadc 100644
--- a/src/gl/gl_hud.cpp
+++ b/src/gl/gl_hud.cpp
@@ -7,7 +7,7 @@
#include <memory>
#include <unistd.h>
#include <spdlog/spdlog.h>
-#include <imgui.h>
+#include <imgui/imgui.h>
#ifdef __linux__
#include <implot.h>
#endif
diff --git a/src/gl/gl_renderer.cpp b/src/gl/gl_renderer.cpp
index 08111f1..69b38a0 100644
--- a/src/gl/gl_renderer.cpp
+++ b/src/gl/gl_renderer.cpp
@@ -65,7 +65,7 @@
//----------------------------------------
#include <spdlog/spdlog.h>
-#include <imgui.h>
+#include <imgui/imgui.h>
#include "gl_renderer.h"
#include <stdio.h>
#include <stdint.h> // intptr_t
diff --git a/src/hud_elements.h b/src/hud_elements.h
index 70deb51..3ccdba8 100644
--- a/src/hud_elements.h
+++ b/src/hud_elements.h
@@ -3,7 +3,7 @@
#include <string>
#include <utility>
#include <map>
-#include <imgui.h>
+#include <imgui/imgui.h>
#include "timing.hpp"
#include <functional>
#include "vulkan/vulkan.h"
diff --git a/src/imgui_utils.h b/src/imgui_utils.h
index f2797e4..3923d3a 100644
--- a/src/imgui_utils.h
+++ b/src/imgui_utils.h
@@ -1,6 +1,6 @@
#pragma once
-#include <imgui.h>
+#include <imgui/imgui.h>
#ifdef __linux__
#include <implot.h>
diff --git a/src/overlay.h b/src/overlay.h
index cad97c2..bf9faf6 100644
--- a/src/overlay.h
+++ b/src/overlay.h
@@ -6,8 +6,8 @@
#include <stdint.h>
#include <vector>
#include <deque>
-#include <imgui.h>
-#include "imgui_internal.h"
+#include <imgui/imgui.h>
+#include <imgui/imgui_internal.h>
#include "overlay_params.h"
#include "hud_elements.h"
diff --git a/src/overlay_params.cpp b/src/overlay_params.cpp
index ab7e37d..5e4bf90 100644
--- a/src/overlay_params.cpp
+++ b/src/overlay_params.cpp
@@ -10,7 +10,7 @@
#include <wordexp.h>
#include <unistd.h>
#endif
-#include "imgui.h"
+#include <imgui/imgui.h>
#include <iostream>
#include <string>
#include <sstream>
diff --git a/src/vulkan.cpp b/src/vulkan.cpp
index ffadf25..b1e8c23 100644
--- a/src/vulkan.cpp
+++ b/src/vulkan.cpp
@@ -37,7 +37,7 @@
#include <sstream>
#include <inttypes.h>
#include <spdlog/spdlog.h>
-#include <imgui.h>
+#include <imgui/imgui.h>
#include "mesa/util/macros.h" // defines "restrict" for vk_util.h
#include "mesa/util/os_socket.h"

View File

@@ -3,7 +3,7 @@
EAPI=8
PYTHON_COMPAT=( python3_{11..13} )
PYTHON_COMPAT=( python3_{11..14} )
inherit flag-o-matic python-single-r1 meson-multilib toolchain-funcs
@@ -13,13 +13,14 @@ MY_PV=$(ver_cut 1-3)
DESCRIPTION="Vulkan and OpenGL overlay for monitoring FPS, sensors, system load and more"
HOMEPAGE="https://github.com/flightlessmango/MangoHud"
VK_HEADERS_VER="1.2.158"
VK_HEADERS_MESON_WRAP_VER="2"
# Check subprojects/vulkan-headers.wrap for both of these values
VK_HEADERS_VER="1.3.283"
VK_HEADERS_MESON_WRAP_VER="1"
SRC_URI="
https://github.com/KhronosGroup/Vulkan-Headers/archive/v${VK_HEADERS_VER}.tar.gz
-> vulkan-headers-${VK_HEADERS_VER}.tar.gz
https://wrapdb.mesonbuild.com/v2/vulkan-headers_${VK_HEADERS_VER}-${VK_HEADERS_MESON_WRAP_VER}/get_patch
https://github.com/mesonbuild/wrapdb/releases/download/vulkan-headers_${VK_HEADERS_VER}-${VK_HEADERS_MESON_WRAP_VER}/vulkan-headers_${VK_HEADERS_VER}-${VK_HEADERS_MESON_WRAP_VER}_patch.zip
-> vulkan-headers-${VK_HEADERS_VER}-${VK_HEADERS_MESON_WRAP_VER}-meson-wrap.zip
"
@@ -56,7 +57,7 @@ BDEPEND="
DEPEND="
${PYTHON_DEPS}
=media-libs/imgui-1.89.9*:=[opengl,vulkan,${MULTILIB_USEDEP}]
=media-libs/imgui-1.91.6*:=[opengl,vulkan,${MULTILIB_USEDEP}]
=media-libs/implot-0.16*:=[${MULTILIB_USEDEP}]
dev-libs/spdlog:=[${MULTILIB_USEDEP}]
dev-libs/libfmt:=[${MULTILIB_USEDEP}]
@@ -70,7 +71,7 @@ DEPEND="
)
wayland? ( dev-libs/wayland[${MULTILIB_USEDEP}] )
mangoapp? (
=media-libs/imgui-1.89.9*[glfw]
=media-libs/imgui-1.91.6*[glfw]
media-libs/glfw[X(+)?,wayland(+)?]
media-libs/glew
)
@@ -93,6 +94,10 @@ RDEPEND="
)
"
PATCHES=(
"${FILESDIR}/${P}-system-imgui.patch"
)
src_unpack() {
default
@@ -107,17 +112,6 @@ src_unpack() {
mv "${WORKDIR}/Vulkan-Headers-${VK_HEADERS_VER}" "${S}/subprojects/" || die
}
src_prepare() {
default
# replace all occurences of "#include <imgui.h>" to "#include <imgui/imgui.h>"
find . -type f -exec sed -i 's|<imgui.h>|<imgui/imgui.h>|g' {} \; || die
find . -type f -exec sed -i 's|"imgui.h"|<imgui/imgui.h>|g' {} \; || die
find . -type f -exec sed -i 's|<imgui_internal.h>|<imgui/imgui_internal.h>|g' {} \; || die
find . -type f -exec sed -i 's|"imgui_internal.h"|<imgui/imgui_internal.h>|g' {} \; || die
find . -type f -exec sed -i 's|"imgui_impl_glfw.h"|<imgui/imgui_impl_glfw.h>|g' {} \; || die
find . -type f -exec sed -i 's|"imgui_impl_opengl3.h"|<imgui/imgui_impl_opengl3.h>|g' {} \; || die
}
multilib_src_configure() {
# workaround for lld
# https://github.com/flightlessmango/MangoHud/issues/1240