[cmake] fix macos mbedtls (#3109)
Signed-off-by: crueter <crueter@eden-emu.dev> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3109
This commit is contained in:
parent
f58097e814
commit
318998cbb5
|
|
@ -128,9 +128,6 @@ if (YUZU_STATIC_BUILD)
|
||||||
## find .a libs first (static, usually)
|
## find .a libs first (static, usually)
|
||||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
||||||
|
|
||||||
## some libraries define a Library::Name_static alternative ##
|
|
||||||
set(YUZU_STATIC_SUFFIX _static)
|
|
||||||
|
|
||||||
## some libraries use CMAKE_IMPORT_LIBRARY_SUFFIX e.g. Harfbuzz ##
|
## some libraries use CMAKE_IMPORT_LIBRARY_SUFFIX e.g. Harfbuzz ##
|
||||||
set(CMAKE_IMPORT_LIBRARY_SUFFIX ".a")
|
set(CMAKE_IMPORT_LIBRARY_SUFFIX ".a")
|
||||||
|
|
||||||
|
|
@ -161,20 +158,22 @@ if (YUZU_STATIC_BUILD)
|
||||||
set(YUZU_USE_BUNDLED_OPENSSL ON)
|
set(YUZU_USE_BUNDLED_OPENSSL ON)
|
||||||
|
|
||||||
set(HTTPLIB_USE_BROTLI_IF_AVAILABLE OFF)
|
set(HTTPLIB_USE_BROTLI_IF_AVAILABLE OFF)
|
||||||
|
|
||||||
|
## some libraries define a Library::Name_static alternative ##
|
||||||
|
set(MBEDTLS_LIB_SUFFIX _static)
|
||||||
elseif(APPLE)
|
elseif(APPLE)
|
||||||
# these libs do not properly provide static libs/let you do it with cmake
|
|
||||||
set(YUZU_USE_CPM ON)
|
set(YUZU_USE_CPM ON)
|
||||||
|
|
||||||
set(YUZU_USE_BUNDLED_FFMPEG ON)
|
set(YUZU_USE_BUNDLED_FFMPEG ON)
|
||||||
set(YUZU_USE_BUNDLED_SDL2 ON)
|
set(YUZU_USE_BUNDLED_SDL2 ON)
|
||||||
set(YUZU_USE_BUNDLED_OPENSSL ON)
|
set(YUZU_USE_BUNDLED_OPENSSL ON)
|
||||||
|
|
||||||
# IMPORTED_IMPLIB not set for imported target
|
# these libs do not properly provide static libs/let you do it with cmake
|
||||||
# TODO(crueter): wtf
|
|
||||||
set(fmt_FORCE_BUNDLED ON)
|
set(fmt_FORCE_BUNDLED ON)
|
||||||
set(SPIRV-Tools_FORCE_BUNDLED ON)
|
set(SPIRV-Tools_FORCE_BUNDLED ON)
|
||||||
set(SPIRV-Headers_FORCE_BUNDLED ON)
|
set(SPIRV-Headers_FORCE_BUNDLED ON)
|
||||||
set(zstd_FORCE_BUNDLED ON)
|
set(zstd_FORCE_BUNDLED ON)
|
||||||
|
set(MbedTLS_FORCE_BUNDLED ON)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1203,7 +1203,7 @@ else()
|
||||||
target_link_libraries(core PUBLIC Boost::headers)
|
target_link_libraries(core PUBLIC Boost::headers)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
target_link_libraries(core PRIVATE fmt::fmt nlohmann_json::nlohmann_json RenderDoc::API MbedTLS::mbedcrypto${YUZU_STATIC_SUFFIX} MbedTLS::mbedtls${YUZU_STATIC_SUFFIX})
|
target_link_libraries(core PRIVATE fmt::fmt nlohmann_json::nlohmann_json RenderDoc::API MbedTLS::mbedcrypto${MBEDTLS_LIB_SUFFIX} MbedTLS::mbedtls${MBEDTLS_LIB_SUFFIX})
|
||||||
# if (MINGW)
|
# if (MINGW)
|
||||||
# target_link_libraries(core PRIVATE ws2_32 mswsock wlanapi)
|
# target_link_libraries(core PRIVATE ws2_32 mswsock wlanapi)
|
||||||
# endif()
|
# endif()
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ if (ENABLE_WEB_SERVICE)
|
||||||
target_link_libraries(yuzu-room PRIVATE web_service)
|
target_link_libraries(yuzu-room PRIVATE web_service)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
target_link_libraries(yuzu-room PRIVATE MbedTLS::mbedcrypto${YUZU_STATIC_SUFFIX} MbedTLS::mbedtls${YUZU_STATIC_SUFFIX})
|
target_link_libraries(yuzu-room PRIVATE MbedTLS::mbedcrypto${MBEDTLS_LIB_SUFFIX} MbedTLS::mbedtls${MBEDTLS_LIB_SUFFIX})
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
target_link_libraries(yuzu-room PRIVATE getopt)
|
target_link_libraries(yuzu-room PRIVATE getopt)
|
||||||
endif()
|
endif()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue