Skip to content
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

Build Hermes from Source #33396

Closed
wants to merge 2 commits into from
Closed

Conversation

cortinico
Copy link
Contributor

@cortinico cortinico commented Mar 8, 2022

Summary:
This commit fully unplugs the ReactAndroid from using hermes from the NPM package and plugs the usage of Hermes via the packages/hermes-engine Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a buildHermesFromSource property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the react-native NPM package and users could potentially toggle which source to use.

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

@facebook-github-bot 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 Mar 8, 2022
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

@react-native-bot react-native-bot added the Platform: Android Android applications. label Mar 8, 2022
@analysis-bot
Copy link

analysis-bot commented Mar 8, 2022

Platform Engine Arch Size (bytes) Diff
ios - universal n/a --

Base commit: 2a5265d
Branch: main

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

cortinico added a commit to cortinico/react-native that referenced this pull request Mar 9, 2022
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: 9879a097e35b51aa67a8e48c766573bbd6df0b7d
@cortinico cortinico requested a review from hramos as a code owner March 9, 2022 08:35
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

cortinico added a commit to cortinico/react-native that referenced this pull request Mar 9, 2022
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: 99452c43adf456156f5280dc37aefb9555ece18a
@analysis-bot
Copy link

analysis-bot commented Mar 9, 2022

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 8,214,093 +14
android hermes armeabi-v7a 7,799,793 +5
android hermes x86 8,587,567 +1
android hermes x86_64 8,538,507 +10
android jsc arm64-v8a 9,882,741 +10
android jsc armeabi-v7a 8,852,979 +3
android jsc x86 9,852,303 +6
android jsc x86_64 10,447,377 +7

Base commit: 2a5265d
Branch: main

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

cortinico added a commit to cortinico/react-native that referenced this pull request Mar 9, 2022
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: f29019a865a594676e9d32d294da55aa24626218
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

cortinico added a commit to cortinico/react-native that referenced this pull request Mar 9, 2022
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: c7a9e6d88901d4ef2b1689f8a9e73b8f19d231d0
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: e5912d24dc11a2cc7044e3615d2ff4c41fcedd30
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D34389875

@react-native-bot
Copy link
Collaborator

This pull request was successfully merged by @cortinico in a3d9892.

When will my fix make it into a release? | Upcoming Releases

@react-native-bot react-native-bot added the Merged This PR has been merged. label Mar 11, 2022
cortinico added a commit to cortinico/react-native that referenced this pull request Mar 12, 2022
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: 107cbe3686daf7607a1f0f75202f24cd80ce64bb
Saadnajmi pushed a commit to Saadnajmi/react-native-macos that referenced this pull request Jan 15, 2023
Summary:
Pull Request resolved: facebook#33396

This commit fully unplugs the `ReactAndroid` from using hermes from the NPM package and plugs the usage of Hermes via the `packages/hermes-engine` Gradle build.

I've used prefab to share the .so between the two builds, so we don't need any extra machinery to make this possible.

Moreover, I've added a `buildHermesFromSource` property, which defaults to false when RN is imported, but is set to true when RN is opened for local development. This should allow us to distribute the `react-native` NPM package and users could potentially toggle which source to use (but see below).

Changelog:
[Android] [Changed] - Build Hermes from Source

Reviewed By: hramos

Differential Revision: D34389875

fbshipit-source-id: 107cbe3686daf7607a1f0f75202f24cd80ce64bb
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 Platform: Android Android applications.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants