react-native-builder-bob icon indicating copy to clipboard operation
react-native-builder-bob copied to clipboard

How would I go about adding Carthage dependencies to the swift UI component package I am authoring?

Open sinewave440hz opened this issue 2 years ago • 2 comments

Ask your Question

I need to build a wrapper around dependencies that are only available as Carthage dependencies. I have successfully added them to a standard tvOS swift project.

I added a cartfile in the same way as in my swift project, but this time in the iOS folder of the actual react-native package I am authoring. Here, carthage updates and builds the dependencies correctly, but they do not compile. There is no way to add the generated xc-frameworks to the package's Xcode project file (there are no options to add frameworks in the package project, only in the embedded example project.

Does anyone have any suggestion on how to proceed with this?

Thanks!

sinewave440hz avatar Nov 14 '21 21:11 sinewave440hz

So I gather that I need to add my xcframeworks to my podspec file. s.vendored_frameworks = "Carthage/Build/niceFramework.xcframework", "Carthage/Build/niceFramework1.xcframework", "Carthage/Build/niceFramework2.xcframework"

The pod install works, but gives me a lot of warnings. (Too many to show apparently, it crashes the ruby script). I'm getting build errors in the Xcode example project too. Maybe this is too much of an edge case to be useful to anyone...?

sinewave440hz avatar Nov 16 '21 13:11 sinewave440hz

So I gather that I need to add my xcframeworks to my podspec file. s.vendored_frameworks = "Carthage/Build/niceFramework.xcframework", "Carthage/Build/niceFramework1.xcframework", "Carthage/Build/niceFramework2.xcframework"

The pod install works, but gives me a lot of warnings. (Too many to show apparently, it crashes the ruby script). I'm getting build errors in the Xcode example project too. Maybe this is too much of an edge case to be useful to anyone...?

Are you able to spot if the pod install warnings start with something like "[!] [Xcodeproj] Generated duplicate UUIDs"?

monholm avatar Nov 18 '21 06:11 monholm