OpenCV in iOS: Class VideoWriter is implemented in both AutoLoop.framework and One of the two will be used. Which one is undefined

I have an ios app that uses opencv and some other libraries. When running it, I see a log:

(lldb) objc[536]: Class VideoWriter is implemented in both /System/Library/PrivateFrameworks/AutoLoop.framework/AutoLoop (0x1f897bd48) and /private/var/containers/Bundle/Application/6AF089E9-121C-41B4-8706-3F63E9F39090/ (0x1057a7888). One of the two will be used. Which one is undefined.

Surely, I can do nothing with AutoLoop.framework. But for the (which is indeed the name of my app since I am using Flutter), I hope I can change it. However, I have searched through all my code and see I do not define VideoWriter by myself. With more searching, it seems the OpenCV defines that (please correct me if I am wrong!). The clue is: At opencv2.framework/Modules/opencv2.swiftmodule/arm64-apple-ios.swiftinterface I see -

extension VideoWriter {
  @nonobjc public convenience init(filename: Swift.String, fourcc: Swift.Int32, fps: Swift.Double, frameSize: opencv2.Size2i, params: [Swift.Int32])

So I guess that is where VideoWriter comes from.

I do not need the videoio submodule of OpenCV, so I am happy to remove it if I can. Indeed, since I link against opencv2.framework and do not use it, it should be already stripped out and I am not sure why it is still there.


  1. Does that conflict really comes from OpenCV? Or I made a wrong conclusion?
  2. What to do to resolve the conflict?

Any help is appreciated!