From 148ff1577452e1ceb722ff4394007656112d8a41 Mon Sep 17 00:00:00 2001 From: Mark Harfouche Date: Mon, 27 Dec 2021 02:21:21 -0500 Subject: [PATCH 1/2] Fixup MSVC source file inclusion for cmake builds --- build/cmake/lib/CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/build/cmake/lib/CMakeLists.txt b/build/cmake/lib/CMakeLists.txt index ec8480d5d..612f667f9 100644 --- a/build/cmake/lib/CMakeLists.txt +++ b/build/cmake/lib/CMakeLists.txt @@ -22,7 +22,11 @@ include_directories(${LIBRARY_DIR} ${LIBRARY_DIR}/common) file(GLOB CommonSources ${LIBRARY_DIR}/common/*.c) file(GLOB CompressSources ${LIBRARY_DIR}/compress/*.c) -file(GLOB DecompressSources ${LIBRARY_DIR}/decompress/*.c ${LIBRARY_DIR}/decompress/*.S) +if (MSVC) + file(GLOB DecompressSources ${LIBRARY_DIR}/decompress/*.c) +else () + file(GLOB DecompressSources ${LIBRARY_DIR}/decompress/*.c ${LIBRARY_DIR}/decompress/*.S) +endif () file(GLOB DictBuilderSources ${LIBRARY_DIR}/dictBuilder/*.c) set(Sources From df5ad5a0f1e087e1202806c8b4baf72d7841edf4 Mon Sep 17 00:00:00 2001 From: Mark Harfouche Date: Wed, 5 Jan 2022 20:36:51 -0500 Subject: [PATCH 2/2] Add a compile option to explicitely disable assembly --- build/cmake/lib/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/build/cmake/lib/CMakeLists.txt b/build/cmake/lib/CMakeLists.txt index 612f667f9..4905bd913 100644 --- a/build/cmake/lib/CMakeLists.txt +++ b/build/cmake/lib/CMakeLists.txt @@ -24,6 +24,7 @@ file(GLOB CommonSources ${LIBRARY_DIR}/common/*.c) file(GLOB CompressSources ${LIBRARY_DIR}/compress/*.c) if (MSVC) file(GLOB DecompressSources ${LIBRARY_DIR}/decompress/*.c) + add_compile_options(-DZSTD_DISABLE_ASM) else () file(GLOB DecompressSources ${LIBRARY_DIR}/decompress/*.c ${LIBRARY_DIR}/decompress/*.S) endif ()