-
Notifications
You must be signed in to change notification settings - Fork 651
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
arm64 simulators & catalyst support #475
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,7 +46,8 @@ function build_host_hermesc { | |
# Utility function to configure an Apple framework | ||
function configure_apple_framework { | ||
local build_cli_tools enable_bitcode | ||
if [[ $1 == iphoneos ]]; then | ||
|
||
if [[ $1 == iphoneos || $1 == catalyst ]]; then | ||
enable_bitcode="true" | ||
else | ||
enable_bitcode="false" | ||
|
@@ -98,22 +99,21 @@ function create_universal_framework { | |
cd ./destroot/Library/Frameworks || exit 1 | ||
|
||
local platforms=("$@") | ||
local args="" | ||
|
||
echo "Creating universal framework for platforms: ${platforms[*]}" | ||
|
||
for i in "${!platforms[@]}"; do | ||
platforms[$i]="${platforms[$i]}/hermes.framework/hermes" | ||
args+="-framework ${platforms[$i]}/hermes.framework " | ||
done | ||
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
Sorry, something went wrong. |
||
|
||
lipo -create -output "${platforms[0]}" "${platforms[@]}" | ||
xcodebuild -create-xcframework $args -output "${platforms[0]}/hermes.xcframework" | ||
|
||
# Once all was linked into a single framework, clean destroot | ||
# from unused frameworks | ||
for platform in "${@:2}"; do | ||
rm -r "$platform" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Any particular reason why this has been removed? This should be reverted. We need to clean up This is because CircleCI will package the entire There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, I've reverted that removal |
||
done | ||
|
||
lipo -info "${platforms[0]}" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Any particular reason why this has been removed? I think this is a good add-on for debugging purposes on the CI. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because lipo -info fails on xcframework with a fatal error: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok |
||
|
||
cd - || exit 1 | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps also replace further use of
$1
with the$platform
alias here?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would actually not use
$platform
here. Further explanation on line 62.