From 78a362581d0c6b66d57daa111b506d770f1b3f14 Mon Sep 17 00:00:00 2001 From: Ryan Houdek Date: Mon, 26 Feb 2024 23:29:14 -0800 Subject: [PATCH] Update xxhash to v0.8.2 Switches to using upstream cmake files. --- .gitmodules | 2 +- CMakeLists.txt | 6 ++++-- External/xxhash | 2 +- FEXCore/Source/CMakeLists.txt | 2 +- Source/Tools/FEXRootFSFetcher/CMakeLists.txt | 2 +- 5 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.gitmodules b/.gitmodules index be1223219..8eb1526cb 100644 --- a/.gitmodules +++ b/.gitmodules @@ -41,7 +41,7 @@ url = https://github.com/FEX-Emu/drm-headers.git [submodule "External/xxhash"] path = External/xxhash - url = https://github.com/FEX-Emu/xxHash.git + url = https://github.com/Cyan4973/xxHash.git [submodule "External/Catch2"] path = External/Catch2 url = https://github.com/catchorg/Catch2.git diff --git a/CMakeLists.txt b/CMakeLists.txt index ce3896ae3..b19cfafa5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -237,8 +237,10 @@ endif() find_package(PkgConfig REQUIRED) find_package(Python 3.0 REQUIRED COMPONENTS Interpreter) -add_subdirectory(External/xxhash/) -include_directories(External/xxhash/) +set(XXHASH_BUNDLED_MODE TRUE) +set(XXHASH_BUILD_XXHSUM FALSE) +set(BUILD_SHARED_LIBS OFF) +add_subdirectory(External/xxhash/cmake_unofficial/) add_definitions(-Wno-trigraphs) add_definitions(-DGLOBAL_DATA_DIRECTORY="${DATA_DIRECTORY}/") diff --git a/External/xxhash b/External/xxhash index ba7375d54..bbb27a5ef 160000 --- a/External/xxhash +++ b/External/xxhash @@ -1 +1 @@ -Subproject commit ba7375d54fbbf7bfd9519b465a146e9a8bf0240f +Subproject commit bbb27a5efb85b92a0486cf361a8635715a53f6ba diff --git a/FEXCore/Source/CMakeLists.txt b/FEXCore/Source/CMakeLists.txt index 4279591fc..1dbf0165e 100644 --- a/FEXCore/Source/CMakeLists.txt +++ b/FEXCore/Source/CMakeLists.txt @@ -194,7 +194,7 @@ endif() # Some defines for the softfloat library list(APPEND DEFINES "-DSOFTFLOAT_BUILTIN_CLZ") -set (LIBS fmt::fmt vixl xxhash FEXHeaderUtils) +set (LIBS fmt::fmt vixl xxHash::xxhash FEXHeaderUtils) if (NOT MINGW_BUILD) list (APPEND LIBS dl) diff --git a/Source/Tools/FEXRootFSFetcher/CMakeLists.txt b/Source/Tools/FEXRootFSFetcher/CMakeLists.txt index b17d0fb72..69fdf8418 100644 --- a/Source/Tools/FEXRootFSFetcher/CMakeLists.txt +++ b/Source/Tools/FEXRootFSFetcher/CMakeLists.txt @@ -3,7 +3,7 @@ set(SRCS Main.cpp XXFileHash.cpp) add_executable(${NAME} ${SRCS}) -list(APPEND LIBS FEXCore Common) +list(APPEND LIBS FEXCore Common xxHash::xxhash) target_include_directories(${NAME} PRIVATE ${CMAKE_SOURCE_DIR}/Source/)