When running locally either via Xcode or using the top command, only the public headers are shown in the MyFramework.framework/Headers folder. But using Bitrise, it populates that folder with all headers - which we’d like to keep private.
If you run the xcodebuild command from a Script step, there’s absolutely no Bitrise specific thing going on. That’s just pure Xcode Command Line tools (xcodebuild), exactly the way you run it.
I’d suggest you to try these local debug/reproduction steps, and let us know if that helps / how that goes: