bielikb / xcframeworks

Demonstration of creating and integrating xcframeworks and their co-op with static libraries and Swift packages
MIT License
536 stars 46 forks source link

"No Such Module" while using a XCFramework of a framework that uses CocoaPods #13

Open cpradobliss opened 2 years ago

cpradobliss commented 2 years ago

Hi! I have created a project that consumes a library using CocoaPods.

I have created an XCFramework of that project using bundle exec fastlane export_xcframework. It worked, but when I try to consume the framework from my SPM project it says that there's "No such module StreamAMGSDK". This error appears in the .swiftinterfacefile:

// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 effective-4.1.50 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target arm64-apple-ios14.0 -enable-objc-interop -enable-library-evolution -swift-version 4 -enforce-exclusivity=checked -O -module-name IMPlayer
import StreamAMGSDK // Error appears here <<<<<<<<
import Swift
import _Concurrency
@_hasMissingDesignatedInitializers public class IMPlayerFactory {
  final public let shared: IMPlayer.IMPlayerFactory
  public func createPlayer(frame: CoreGraphics.CGRect, youboraAccountCode: Swift.Int? = nil, partnerId: Swift.Int) -> StreamAMGSDK.AMGPlayKit
  @objc deinit
}

There's something I can do to make this XCFramework work by having this library included?