Skip to content

Fix Mac Catalyst framework symlinks in published iOS prebuilds - #59819

Open
theeket wants to merge 1 commit into
react:mainfrom
theeket:fix/preserve-ios-prebuild-symlinks
Open

theeket wants to merge 1 commit into
react:mainfrom
theeket:fix/preserve-ios-prebuild-symlinks

Conversation

@theeket

@theeket theeket commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Summary:

Addresses the React Dependencies and Core framework symlink corruption reported in #55540.

Mac Catalyst frameworks use a versioned bundle layout (as macOS): the framework binary and Resources point into Versions/Current, which points to the actual version directory. These symlinks must survive packaging. Although the local build scripts (including local-generated .tar.gz) work correctly, all the maven publishing have broken Mac Catalyst slice.

The correct framework → artifact upload loses symlinks → download
→ compose XCFramework → tar.gz → Maven

Now, both iOS prebuild workflows upload raw Build/Products directories. GH's artifact ZIP writer explicitly resolves symlinks with realpath() and stores their targets as ordinary files. (See implementation) So, the final .tar.gz archives faithfully package that already-damaged layout, and Maven publishes those archives.

The problem predates the reported 0.84: published dependency archives inspected from 0.79.2, 0.83.0, 0.84.0, and 0.88.1 all lack Catalyst symlinks. The inspected 0.88.1 React Core archive has the same problem.

Hermes already protects this handoff with a “Compress slices to preserve Symlinks” step. This PR follows the archive-before-upload approach to React Native's workflows.


Changes in prebuild-ios-core.yml and prebuild-ios-dependencies.yml:

  • Archive slice products before upload, including products restored from cache; extract them before XCFramework composition.
  • Check the Catalyst binary, Resources, and Versions/Current symlinks before final packaging.
  • Bump composed-artifact cache keys so previous damaged archives cannot bypass the fix.
Incorrect (Resolved to file) Correct (Preserve symlinks)
x1 x2

Changelog:

[IOS] [FIXED] - Preserve Mac Catalyst framework symlinks in published React Native prebuild artifacts.

Test Plan:

(Update) Prebuilt frameworks test passed, and have correct symlinks

React Dependencies: Debug, Release
React Core: Debug, Release

Composed XCFramework: Debug, Release

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 6, 2026
@facebook-github-tools facebook-github-tools Bot added the Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team. label Nov 6, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant