facebook / buck

A fast build system that encourages the creation of small, reusable modules over a variety of platforms and languages.
https://buck.build
Apache License 2.0
8.56k stars 1.16k forks source link

[Discussion] XCFrameworks Support #2594

Open Lcsmarcal opened 3 years ago

Lcsmarcal commented 3 years ago

Hey peeps. Last week I was taking a look at support XCFramework on Buck, for both build and project commands.

XCFrameworks is a new bundle type that contains a framework per platform, so you can have a framework for iPhoneOS, WatchOS, MacOS, and their respective simulators in the same XCFramework bundle. And now XCFramework is becoming the main way to distribute binaries. In the last version of the Xcode when using the old framework bundle you already get this kind of error:

Building for iOS Simulator, but the linked and embedded framework 'FirebaseCore.framework' was built for iOS + iOS Simulator.

So I needed to take a look at how Buck can support this new framework bundle. And I came to this solution (#2593), which I'm not very happy with and it's still a kinda "hacky" solution.

It's working both for Buck and Xcode, but here are the topics that I'm not very comfortable with that solution:

Lcsmarcal commented 3 years ago

cc @milend @rajyengi

narlei commented 3 years ago

+1

rafabertholdo commented 3 years ago

any news related into merging this? Apple is not selling x64 macs anymore, people who use carthage to build their frameworks depends on xcframework.