Skip to content

Commit eaba0e6

Browse files
committed
cmake: append '-framework UIKit' for videoio/imgcodecs module
1 parent f1c8e04 commit eaba0e6

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

modules/imgcodecs/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,9 @@ if(IOS)
9292
list(APPEND imgcodecs_srcs ${CMAKE_CURRENT_LIST_DIR}/src/ios_conversions.mm)
9393
list(APPEND IMGCODECS_LIBRARIES "-framework Accelerate" "-framework CoreGraphics" "-framework QuartzCore" "-framework AssetsLibrary")
9494
endif()
95+
if(APPLE_FRAMEWORK)
96+
list(APPEND IMGCODECS_LIBRARIES "-framework UIKit")
97+
endif()
9598

9699
if(UNIX)
97100
#these variables are set by CHECK_MODULE macro

modules/videoio/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ if(IOS)
210210
${CMAKE_CURRENT_LIST_DIR}/src/cap_ios_video_camera.mm)
211211

212212
list(APPEND VIDEOIO_LIBRARIES "-framework Accelerate" "-framework AVFoundation" "-framework CoreGraphics" "-framework CoreImage" "-framework CoreMedia" "-framework CoreVideo" "-framework QuartzCore" "-framework AssetsLibrary")
213-
if(APPLE_FRAMEWORK AND BUILD_SHARED_LIBS)
213+
if(APPLE_FRAMEWORK)
214214
list(APPEND VIDEOIO_LIBRARIES "-framework UIKit")
215215
endif()
216216
endif()

0 commit comments

Comments
 (0)