aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorHoward Su <howard0su@gmail.com>2023-04-22 16:18:20 +0800
committerGitHub <noreply@github.com>2023-04-22 11:18:20 +0300
commit7e312f165c5047d6e16680d1eebc83055e95c313 (patch)
tree74e4365c5f6c99ce1db413c635468b5b63acf86c /CMakeLists.txt
parent872c365a9176a011b13d31269bb3121fa89c37e1 (diff)
cmake : fix build under Windows when enable BUILD_SHARED_LIBS (#1100)
* Fix build under Windows when enable BUILD_SHARED_LIBS * Make AVX512 test on Windows to build the shared libs
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2c3c601..2d4e30e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -201,6 +201,10 @@ endif()
if (MSVC)
add_compile_definitions(_CRT_SECURE_NO_WARNINGS)
+
+ if (BUILD_SHARED_LIBS)
+ set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
+ endif()
endif()
if (LLAMA_LTO)