chore: catch --as-needed (see gh #184)

This commit is contained in:
Marcus Holland-Moritz 2024-01-24 11:49:42 +01:00
parent 22c079a4ca
commit 39d87c9c98

View File

@ -284,6 +284,10 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
endforeach()
set(MSVC_USE_STATIC_RUNTIME ON CACHE BOOL "static build")
else()
if(CMAKE_EXE_LINKER_FLAGS MATCHES "--as-needed")
message(FATAL_ERROR "DwarFS cannot be built with --as-needed")
endif()
endif()
set(ZSTD_INCLUDE_DIR