Skip to content

Commit

Permalink
CMake fixes
Browse files Browse the repository at this point in the history
Thanks to @RipleyTom

Co-Authored-By: RipleyTom <RipleyTom@users.noreply.github.com>
  • Loading branch information
elad335 and RipleyTom committed May 14, 2024
1 parent 6d8575d commit 6bceebb
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 11 deletions.
12 changes: 5 additions & 7 deletions 3rdparty/zstd/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@

project(3rdparty_zstd)

add_library(3rdparty_zstd INTERFACE)
option(ZSTD_BUILD_PROGRAMS "BUILD PROGRAMS" OFF)
option(ZSTD_BUILD_SHARED "BUILD SHARED LIBRARIES" OFF)
option(ZSTD_BUILD_STATIC "BUILD STATIC LIBRARIES" ON)

add_subdirectory(zstd/build/cmake EXLUDE_FROM_ALL)

target_include_directories(3rdparty_zstd INTERFACE zstd zstd/lib)

add_library(3rdparty_zstd INTERFACE)
target_link_libraries(3rdparty_zstd INTERFACE libzstd_static)
2 changes: 0 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,6 @@ if(MSVC)
add_compile_options(/wd4530 /utf-8) # C++ exception handler used, but unwind semantics are not enabled
endif()

set(ALLOW_DUPLICATE_CUSTOM_TARGETS TRUE)

add_subdirectory(3rdparty)

if (DISABLE_LTO)
Expand Down
2 changes: 1 addition & 1 deletion rpcs3/Emu/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ endif()

target_link_libraries(rpcs3_emu
PRIVATE
3rdparty::zlib 3rdparty::yaml-cpp
3rdparty::zlib 3rdparty::yaml-cpp 3rdparty::zstd
PUBLIC
3rdparty::libevdev 3rdparty::flatbuffers)

Expand Down
2 changes: 1 addition & 1 deletion rpcs3/util/serialization_ext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include "serialization_ext.hpp"

#include <zlib.h>
#include <3rdparty/zstd/zstd/lib/zstd.h>
#include <zstd.h>

LOG_CHANNEL(sys_log, "SYS");

Expand Down

0 comments on commit 6bceebb

Please sign in to comment.