Build: Reduce library scope

This commit is contained in:
Stenzek 2023-10-16 20:00:33 +10:00
parent 9501439d6b
commit db675cf5d0
No known key found for this signature in database
2 changed files with 3 additions and 2 deletions

View file

@ -62,8 +62,8 @@ add_library(common
target_include_directories(common PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..") target_include_directories(common PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_include_directories(common PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..") target_include_directories(common PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..")
target_link_libraries(common PUBLIC fmt Threads::Threads vulkan-headers fast_float) target_link_libraries(common PUBLIC fmt Threads::Threads fast_float)
target_link_libraries(common PRIVATE stb libchdr zlib minizip Zstd::Zstd "${CMAKE_DL_LIBS}") target_link_libraries(common PRIVATE stb zlib minizip Zstd::Zstd "${CMAKE_DL_LIBS}")
if(WIN32) if(WIN32)
target_sources(common PRIVATE target_sources(common PRIVATE

View file

@ -187,6 +187,7 @@ if(ENABLE_VULKAN)
vulkan_texture.h vulkan_texture.h
) )
target_compile_definitions(util PUBLIC "ENABLE_VULKAN=1") target_compile_definitions(util PUBLIC "ENABLE_VULKAN=1")
target_link_libraries(util PUBLIC vulkan-headers)
endif() endif()
if(ENABLE_SDL2) if(ENABLE_SDL2)