Re-enable bundling of hermesc inside the react-native NPM package (#33677)
Summary: This PR re-enables bundling of the precompiled `hermesc` binary inside the react-native NPM package. To handle this I've stripped over all the unnecessary files and kept only the relevant binary. It now follows the same structure as the `hermes-engine` NPM package. ## Changelog [Internal] - Re-enable bundling of hermesc inside the react-native NPM package Pull Request resolved: https://github.com/facebook/react-native/pull/33677 Test Plan: Will wait for a successful CI job to produce a commitlies of RN. https://app.circleci.com/pipelines/github/facebook/react-native/13020/workflows/9b59c6e0-4e90-4008-be73-aaa3155cefc9/jobs/248841 Here the output of the RN commitlies with the file correctly placed: ``` tar -tvf ~/Downloads/react-native-1000.0.0-1520d36ba.tgz | grep hermesc -rwxr-xr-x 0 0 0 3516952 Oct 26 1985 package/sdks/hermesc/linux64-bin/hermesc -rwxr-xr-x 0 0 0 2618232 Oct 26 1985 package/sdks/hermesc/osx-bin/hermesc -rwxr-xr-x 0 0 0 1613312 Oct 26 1985 package/sdks/hermesc/win64-bin/hermesc.exe ``` Reviewed By: neildhar Differential Revision: D35784619 Pulled By: cortinico fbshipit-source-id: 334ed03c40f6838ae8365a1f1c6e86e38a8dbc59
This commit is contained in:
Родитель
0916df9951
Коммит
ae3c426c58
|
@ -1085,15 +1085,16 @@ jobs:
|
|||
mkdir -p ~/.ssh
|
||||
echo '|1|If6MU203eXTaaWL678YEfWkVMrw=|kqLeIAyTy8pzpj8x8Ae4Fr8Mtlc= ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==' >> ~/.ssh/known_hosts
|
||||
- checkout
|
||||
# TODO: (hramos) Filter out unnecessary files before adding Hermes Compiler to package
|
||||
# - *attach_hermes_workspace
|
||||
# - run:
|
||||
# name: Move hermesc binaries to sdks/hermesc
|
||||
# command: |
|
||||
# curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -
|
||||
# apt update && apt install -y jq
|
||||
# mkdir -p ./sdks/hermesc
|
||||
# cp -R $HERMES_WS_DIR/hermesc/* ./sdks/hermesc
|
||||
- *attach_hermes_workspace
|
||||
- run:
|
||||
name: Move hermesc binaries to sdks/hermesc
|
||||
command: |
|
||||
mkdir -p ./sdks/hermesc/linux64-bin
|
||||
mkdir -p ./sdks/hermesc/osx-bin
|
||||
mkdir -p ./sdks/hermesc/win64-bin
|
||||
cp $HERMES_WS_DIR/hermesc/linux/bin/hermesc ./sdks/hermesc/linux64-bin/hermesc
|
||||
cp $HERMES_WS_DIR/hermesc/macos/bin/hermesc ./sdks/hermesc/osx-bin/hermesc
|
||||
cp $HERMES_WS_DIR/hermesc/windows/bin/Release/hermesc.exe ./sdks/hermesc/win64-bin/hermesc.exe
|
||||
|
||||
- run_yarn
|
||||
- install_buck_tooling
|
||||
|
@ -1227,9 +1228,8 @@ workflows:
|
|||
- build_npm_package:
|
||||
# Build a release package on every untagged commit, but do not publish to npm.
|
||||
publish_npm_args: --dry-run
|
||||
# TODO: (hramos) Slim down Hermes Compiler files before adding to react-native npm
|
||||
# requires:
|
||||
# - store_hermesc
|
||||
requires:
|
||||
- store_hermesc
|
||||
- test_js:
|
||||
run_disabled_tests: false
|
||||
- test_android:
|
||||
|
@ -1301,9 +1301,8 @@ workflows:
|
|||
context: react-native-bot
|
||||
publish_npm_args: --release
|
||||
filters: *only_release_tags
|
||||
# TODO: (hramos) Slim down Hermes Compiler files before adding to react-native npm
|
||||
# requires:
|
||||
# - store_hermesc
|
||||
requires:
|
||||
- store_hermesc
|
||||
|
||||
analysis:
|
||||
unless: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
|
@ -1350,6 +1349,5 @@ workflows:
|
|||
|
||||
- build_npm_package:
|
||||
publish_npm_args: --nightly
|
||||
# TODO: (hramos) Slim down Hermes Compiler files before adding to react-native npm
|
||||
# requires:
|
||||
# - store_hermesc
|
||||
requires:
|
||||
- store_hermesc
|
||||
|
|
Загрузка…
Ссылка в новой задаче