date-tz for fbsd, force submodule zydis

This commit is contained in:
lizzie 2026-01-16 06:33:11 +00:00
parent 4ab2cfc5da
commit b0b906ac7f
3 changed files with 10 additions and 14 deletions

View File

@ -245,10 +245,7 @@ find_package(VulkanMemoryAllocator 3.1.0 CONFIG)
find_package(xbyak 7.07 CONFIG)
find_package(xxHash 0.8.2 MODULE)
find_package(ZLIB 1.3 MODULE)
# Outdated zydis from ports
if (NOT ${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
find_package(Zydis 5.0.0 CONFIG)
endif()
find_package(Zydis 5.0.0 MODULE)
find_package(pugixml 1.14 CONFIG)
if (APPLE)
find_package(date 3.0.1 CONFIG)
@ -1196,7 +1193,7 @@ if (APPLE)
# Replacement for std::chrono::time_zone
target_link_libraries(shadps4 PRIVATE date::date-tz epoll-shim)
elseif (${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
target_link_libraries(shadps4 PRIVATE epoll-shim)
target_link_libraries(shadps4 PRIVATE date::date-tz epoll-shim)
endif()
if (WIN32)

View File

@ -240,25 +240,26 @@ endif()
set(HWINFO_STATIC ON)
add_subdirectory(hwinfo)
# Apple-only dependencies
if (APPLE)
if (APPLE OR ${CMAKE_SYSTEM_NAME} STREQUAL "FreeBSD")
# date
if (NOT TARGET date::date-tz)
option(BUILD_TZ_LIB "" ON)
option(USE_SYSTEM_TZ_DB "" ON)
add_subdirectory(date)
endif()
if (NOT TARGET epoll-shim)
add_subdirectory(epoll-shim)
endif()
endif()
# Apple-only dependencies
if (APPLE)
# MoltenVK
if (NOT TARGET MoltenVK)
set(MVK_EXCLUDE_SPIRV_TOOLS ON)
set(MVK_USE_METAL_PRIVATE_API ON)
add_subdirectory(MoltenVK)
endif()
if (NOT TARGET epoll-shim)
add_subdirectory(epoll-shim)
endif()
endif()
#windows only

View File

@ -500,10 +500,8 @@ s32 PS4_SYSV_ABI sceKernelConvertUtcToLocaltime(time_t time, time_t* local_time,
if (dst_sec != nullptr) {
*dst_sec = res == TIME_ZONE_ID_DAYLIGHT ? -_dstbias : 0;
}
#elif defined(__FreeBSD__)
// todo
#else
#if defined(__APPLE__)
#if defined(__APPLE__) || defined(__FreeBSD__)
// std::chrono::current_zone() not available yet.
const auto* time_zone = date::current_zone();
#else