diff --git a/.gitmodules b/.gitmodules index 0096c4f..ee9c46d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,6 @@ [submodule "vendor/nerutils"] path = vendor/nerutils url = https://git.neru.rip/neru/nerutils +[submodule "vendor/simdjson"] + path = vendor/simdjson + url = https://github.com/simdjson/simdjson diff --git a/CMakeLists.txt b/CMakeLists.txt index 7f65610..d0499cf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -53,13 +53,25 @@ else() target_compile_options(dbd-unlocker-warnings INTERFACE -Wall -Wextra -Werror) endif() +# ------------------------------ +# simdjson without errors +# ------------------------------ +add_library(simdjson-wrapped INTERFACE) +target_link_libraries(simdjson-wrapped INTERFACE simdjson) + +if(CMAKE_GENERATOR MATCHES "Visual Studio") + target_compile_options(simdjson-wrapped INTERFACE /W0) +else() + target_compile_options(simdjson-wrapped INTERFACE -w) +endif() + + # ------------------------------ # unlocker # ------------------------------ file(GLOB_RECURSE UNLOCKER_SOURCES CONFIGURE_DEPENDS "src/unlocker/*.cpp" "src/unlocker/*.h") add_executable(dbd-unlocker ${UNLOCKER_SOURCES}) -target_link_libraries(dbd-unlocker PRIVATE dbd-unlocker-warnings ${OPENSSL_LIBRARIES} nerutils wsock32 ws2_32 wininet) -target_include_directories(dbd-unlocker PRIVATE ${OPENSSL_INCLUDE__DIR}) +target_link_libraries(dbd-unlocker PRIVATE dbd-unlocker-warnings OpenSSL::SSL OpenSSL::Crypto nerutils wsock32 ws2_32 wininet simdjson-wrapped) set_property(TARGET dbd-unlocker PROPERTY USE_FOLDERS ON) set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT dbd-unlocker) diff --git a/vendor/simdjson b/vendor/simdjson new file mode 160000 index 0000000..5395aac --- /dev/null +++ b/vendor/simdjson @@ -0,0 +1 @@ +Subproject commit 5395aacb8b63db4bd3bd14f87f63da56a711d779