Disable empty static prefix for Windows. (#629)

This commit is contained in:
Matthew Parkinson
2023-08-25 14:17:04 +01:00
committed by GitHub
parent c2e4a12e21
commit 7b597335ae

View File

@@ -61,6 +61,10 @@ if (SNMALLOC_SANITIZER)
message(STATUS "Using sanitizer=${SNMALLOC_SANITIZER}")
endif()
if(MSVC AND SNMALLOC_STATIC_LIBRARY AND (SNMALLOC_STATIC_LIBRARY_PREFIX STREQUAL ""))
message(FATAL_ERROR "Empty static library prefix not supported on MSVC")
endif()
# If CheckLinkerFlag doesn't exist then provide a dummy implementation that
# always fails. The fallback can be removed when we move to CMake 3.18 as the
# baseline.