From 4f80daab080d85ba878945e37cd8356430bbbef0 Mon Sep 17 00:00:00 2001 From: Tony Wasserka Date: Tue, 3 Sep 2024 16:04:54 +0200 Subject: [PATCH] Add silly workaround for jemalloc being an OBJECT target --- FEXCore/Source/CMakeLists.txt | 8 ++++++-- FEXCore/Source/Nothing.cpp | 0 2 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 FEXCore/Source/Nothing.cpp diff --git a/FEXCore/Source/CMakeLists.txt b/FEXCore/Source/CMakeLists.txt index ec02d8daf0..d5c5810030 100644 --- a/FEXCore/Source/CMakeLists.txt +++ b/FEXCore/Source/CMakeLists.txt @@ -377,10 +377,14 @@ if (NOT MINGW_BUILD) # Only needed for targets that run emulation. For others, use JemallocDummy. add_library(JemallocLibs INTERFACE) if (ENABLE_JEMALLOC) - target_link_libraries(JemallocLibs INTERFACE FEX_jemalloc) + add_library(JemallocLibsSillyWorkaround Nothing.cpp) + target_link_libraries(JemallocLibsSillyWorkaround PRIVATE FEX_jemalloc) + target_link_libraries(JemallocLibs INTERFACE JemallocLibsSillyWorkaround) endif() if (ENABLE_JEMALLOC_GLIBC_ALLOC) - target_link_libraries(JemallocLibs INTERFACE FEX_jemalloc_glibc) + add_library(JemallocLibsSillyWorkaround2 Nothing.cpp) + target_link_libraries(JemallocLibsSillyWorkaround PRIVATE FEX_jemalloc_glibc) + target_link_libraries(JemallocLibs INTERFACE JemallocLibsSillyWorkaround2) endif() endif() diff --git a/FEXCore/Source/Nothing.cpp b/FEXCore/Source/Nothing.cpp new file mode 100644 index 0000000000..e69de29bb2