-
Notifications
You must be signed in to change notification settings - Fork 24.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ld_classic flag to Hermes when building for Xcode 15 #39516
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
facebook-github-bot
added
CLA Signed
This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
p: Facebook
Partner: Facebook
Partner
fb-exported
labels
Sep 18, 2023
This pull request was exported from Phabricator. Differential Revision: D49368675 |
Base commit: 1b7e26c |
) Summary: With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. ## Changelog: [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675
cipolleschi
pushed a commit
to cipolleschi/react-native
that referenced
this pull request
Sep 18, 2023
) Summary: With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. ## Changelog: [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675
cipolleschi
force-pushed
the
export-D49368675
branch
from
September 18, 2023 12:17
333d2d9
to
5bfb192
Compare
This pull request was exported from Phabricator. Differential Revision: D49368675 |
cipolleschi
force-pushed
the
export-D49368675
branch
from
September 18, 2023 12:17
5bfb192
to
f73dac8
Compare
This pull request was exported from Phabricator. Differential Revision: D49368675 |
This pull request has been merged in 8a5b2d6. |
Titozzz
pushed a commit
that referenced
this pull request
Sep 19, 2023
Summary: Pull Request resolved: #39516 With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675 fbshipit-source-id: 62d8ed81855c426f56ed94b6a2d6da2eb882b355
Titozzz
pushed a commit
that referenced
this pull request
Sep 19, 2023
Summary: Pull Request resolved: #39516 With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675 fbshipit-source-id: 62d8ed81855c426f56ed94b6a2d6da2eb882b355
Titozzz
pushed a commit
that referenced
this pull request
Sep 19, 2023
Summary: Pull Request resolved: #39516 With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675 fbshipit-source-id: 62d8ed81855c426f56ed94b6a2d6da2eb882b355
Titozzz
pushed a commit
that referenced
this pull request
Sep 19, 2023
Summary: Pull Request resolved: #39516 With Xcode15, Apple rewrote the C++ linker. This is a breaking change that does not work with weak symbols. As a workaround, apple is suggesting to add `-ld_classic` to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally. With this change, we introduce a couple of checks in the Hermes build logic: 1. Detect the version of Xcode that is used 2. Add the new flag to `HERMES_EXTRA_LINKER_FLAGS` if Xcode version is 15. [Internal] - Make hermes build properly with Xcode 15 Reviewed By: cortinico, dmytrorykun Differential Revision: D49368675 fbshipit-source-id: 62d8ed81855c426f56ed94b6a2d6da2eb882b355
This was referenced Sep 21, 2023
This was referenced Oct 11, 2023
Merged
This was referenced Nov 1, 2023
This was referenced Jan 4, 2024
This was referenced Feb 28, 2024
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.
fb-exported
Merged
This PR has been merged.
p: Facebook
Partner: Facebook
Partner
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary:
With Xcode15, Apple rewrote the C++ linker.
This is a breaking change that does not work with weak symbols.
As a workaround, apple is suggesting to add
-ld_classic
to the linker in order to readd support for weak symbols. The flag does not exists for Xcode 14.3 or lower, so we need to add it conditionally.With this change, we introduce a couple of checks in the Hermes build logic:
HERMES_EXTRA_LINKER_FLAGS
if Xcode version is 15.Changelog:
[Internal] - Make hermes build properly with Xcode 15
Differential Revision: D49368675