Skip to content

Commit

Permalink
fix: Vulkan uses proper CMake Vulkan target
Browse files Browse the repository at this point in the history
  • Loading branch information
EduMenges committed Nov 13, 2024
1 parent 630d593 commit 51e3c68
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.6)
cmake_minimum_required(VERSION 3.24)
# Versioning stuff
file(STRINGS "${CMAKE_CURRENT_LIST_DIR}/include/MNN/MNNDefine.h" MNN_DEFINE)
string(REGEX MATCH "MNN_VERSION_MAJOR [0-9]+" MNN_VERSION_MAJOR_DEFINE ${MNN_DEFINE})
Expand Down
4 changes: 2 additions & 2 deletions source/backend/vulkan/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ endif()

include_directories("./")
if(MNN_USE_SYSTEM_LIB)
find_package(Vulkan REQUIRED)
set(MNN_VULKAN_LIBS ${Vulkan_LIBRARIES} PARENT_SCOPE)
find_package(Vulkan REQUIRED GLOBAL)
set(MNN_VULKAN_LIBS Vulkan::Vulkan PARENT_SCOPE)
else()
add_definitions(-DMNN_USE_LIB_WRAPPER)
endif()
Expand Down

0 comments on commit 51e3c68

Please sign in to comment.