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

Use debug/release tarballs in hermes-engine Pod #34761

Closed
wants to merge 3 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Use debug/release tarballs in hermes-engine Pod
Summary:
Separate debug and release tarballs are built in CI. Use the appropriate Hermes artifacts tarball when building hermes-engine.

Changelog:
[iOS] [Changed] - Remove debugger from Hermes when building for release

Differential Revision: D39698499

fbshipit-source-id: 765b73dd0a733e15cee52ae007036be4572b4225
  • Loading branch information
hramos authored and facebook-github-bot committed Sep 22, 2022
commit 6da6dfd5a89bd45949fdaaec4d2e0d13b9be968b
21 changes: 10 additions & 11 deletions sdks/hermes-engine/hermes-engine.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
require "json"

module HermesHelper
BUILD_TYPE = :debug
# BUILD_TYPE = :release
BUILD_TYPE = ENV['PRODUCTION'] == "1" ? :release : :debug
end

react_native_path = File.join(__dir__, "..", "..")
Expand Down Expand Up @@ -40,7 +39,7 @@ elsif File.exists?(hermestag_file) && isInCI
source[:git] = git
source[:tag] = hermestag
else
source[:http] = "https://github.com/facebook/react-native/releases/download/v#{version}/hermes-runtime-darwin-v#{version}.tar.gz"
source[:http] = "https://github.com/facebook/react-native/releases/download/v#{version}/hermes-runtime-darwin-#{HermesHelper::BUILD_TYPE == :debug ? "debug" : "release"}-v#{version}.tar.gz"
end

Pod::Spec.new do |spec|
Expand Down Expand Up @@ -69,17 +68,17 @@ Pod::Spec.new do |spec|

if source[:git] then
spec.prepare_command = <<-EOS
BUILD_TYPE=#{HermesHelper::BUILD_TYPE == :debug ? "Debug" : "Release"}
BUILD_TYPE=#{HermesHelper::BUILD_TYPE == :debug ? "Debug" : "Release"}

# Set HERMES_OVERRIDE_HERMESC_PATH if pre-built HermesC is available
#{File.exist?(import_hermesc_file) ? "export HERMES_OVERRIDE_HERMESC_PATH=#{import_hermesc_file}" : ""}
#{File.exist?(import_hermesc_file) ? "echo \"Overriding HermesC path...\"" : ""}
# Set HERMES_OVERRIDE_HERMESC_PATH if pre-built HermesC is available
#{File.exist?(import_hermesc_file) ? "export HERMES_OVERRIDE_HERMESC_PATH=#{import_hermesc_file}" : ""}
#{File.exist?(import_hermesc_file) ? "echo \"Overriding HermesC path...\"" : ""}

# Build iOS framework
./utils/build-ios-framework.sh
# Build iOS framework
./utils/build-ios-framework.sh

# Build Mac framework
./utils/build-mac-framework.sh
# Build Mac framework
./utils/build-mac-framework.sh
EOS
end
end