Disable vulkan in Windows build when HAVE_VULKAN is off and other cmake build fixes. (#11118)

* Make WolfSSL build support multi-config generator.
Fix a build error in Windows when using QT's moc.
Disable vulkan in Windows build when HAVE_VULKAN is off.

* add WIN32_LEAN_AND_MEAN definition to VS project.
add HAVE_VULKAN definition to VS project.
Define NTSTATUS in main.cpp.
This commit is contained in:
陈俊嘉 2021-11-13 23:11:49 +08:00 committed by GitHub
parent 8b3ed7b599
commit 05881ffa62
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 27 additions and 26 deletions

View file

@ -27,18 +27,7 @@ else()
add_subdirectory(wolfssl EXCLUDE_FROM_ALL)
# TODO(cjj19970505@live.cn)
# This only works in single-config generator
# For a multi-config generator, we need to provide different wolfssl binaries for different config
if (GENERATOR_IS_MULTI_CONFIG)
message( FATAL_ERROR "RPCS3 can only be configured using single-config generator." )
endif()
if(MSVC)
set(WolfSSL_LIBRARY "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/${CMAKE_BUILD_TYPE}/wolfssl.lib" CACHE INTERNAL "")
else()
set(WolfSSL_LIBRARY "${CMAKE_CURRENT_BINARY_DIR}/wolfssl/libwolfssl.a" CACHE INTERNAL "")
endif()
set(WolfSSL_LIBRARY "$<TARGET_FILE:wolfssl>" CACHE INTERNAL "")
# "${CMAKE_CURRENT_SOURCE_DIR}/wolfssl/wolfssl/" provides openssl headers
# So that curl can be built on an environment where openssl headers are not provided