about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2024-03-04 13:39:20 +0100
committerptitSeb <sebastien.chev@gmail.com>2024-03-04 13:40:57 +0100
commit460fa3f3d76150f464afc1ab4c864b1e628427c8 (patch)
tree160d3a9b0b8748a00b0b70f89ccf266794241d58 /src
parent61de3532c2fe1193e13c42080f434a6230cd83bd (diff)
downloadbox64-460fa3f3d76150f464afc1ab4c864b1e628427c8.tar.gz
box64-460fa3f3d76150f464afc1ab4c864b1e628427c8.zip
Added libstdc++ when loading libGL (only if libgcc_s is already loaded), helps some linux Unity games
Diffstat (limited to 'src')
-rw-r--r--src/wrapped/wrappedlibgl.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/wrapped/wrappedlibgl.c b/src/wrapped/wrappedlibgl.c
index f7d7633e..932af0e2 100644
--- a/src/wrapped/wrappedlibgl.c
+++ b/src/wrapped/wrappedlibgl.c
@@ -435,6 +435,12 @@ static void* find_glGetVkProcAddrNV_Fct(void* fct)
         s->resolved = 1;                                                        \
         s->addr = (uintptr_t)find_glXSwapIntervalEXT_Fct(symb);                 \
     }                                                                           \
+    if(GetLibInternal("libgcc_s.so.1")) {                                       \
+        setNeededLibs(lib, 1, "libstdc++.so.6");                                \
+    }                                                                           \
+
+// This is a small hack to allow loading of libstdc++ as a dependancy for libGL as this is a the case with mesa. Some game, like Mini Metro on Steam don't have 
+// libstdc++.so.6 as a dependancy and yet needs it to run properly, rellying on other dependancies to work
 
 #include "wrappedlib_init.h"