find_library or add_library does not work with xcframework for iOS/Mac

If we are building a framework containing an iOS and iOS simulator slice then we have to use xcframework (Xcode 13 only supports xcframeworks) but cmake does not look like support it. Is there a way to use xcframework in cmake.

Not currently, at least not with direct support from CMake. There’s some discussion for at least part of the picture in issue 21752.