-
Notifications
You must be signed in to change notification settings - Fork 194
Use Swift SDKs to generate symbols for Linux targets and armv7 (using swift-sdk-generator) #399
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
Conversation
- Must be run before running vendor-boringssl script
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.
Shiny, looking really good. A few quick notes.
- Remove the gRPC license text and further expand what the script does instead. - Add variables for the distro name and version to be used throughout.
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.
This is very nice, thanks so much @xtremekforever!
| DOWNLOAD_FILE=swift-${SWIFT_VERSION}-RELEASE-${DISTRO_NAME}-${DISTRO_VERSION}-armv7-install | ||
| DOWNLOAD_PATH="${TMPDIR}/${DOWNLOAD_FILE}" | ||
| echo "Downloading armv7 runtime..." | ||
| wget -nc https://github.com/swift-embedded-linux/armhf-debian/releases/download/${SWIFT_VERSION}/${DOWNLOAD_FILE}.tar.gz && \ |
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.
@xtremekforever what's the plan for upstreaming build scripts that produce these tarballs? IMO these belong to swiftlang/swift with a corresponding preset that potentially could be running on CI to track regressions
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 wonder if the best solution could be to provide a separate build.sh script that can be run from the Apple CIs? I would LOVE to upstream this but don't know what steps are the right ones to take. I will need some help.
@MaxDesiatov is this something we could discuss, perhaps on Slack or even in a Discord call? I just don't know how to get this "into" swiftlang/swift without monumental effort.
Swift SDK solution for adding armv7 symbols for swift-crypto using the swift-sdk-generator.
Motivation:
As outlined in #223, the necessary symbols for armv7 are missing from swift-crypto, and we'd like to add them in some way that could be accepted by the team. It was discussed that using Swift SDKs generated from the swift-sdk-generator could be a solution that could be easily vetted, since the swift-sdk-generator is a component maintained by Apple and the swiftlang organization.
Modifications:
./scripts/generate-linux-sdks.shscript to clone & build the swift-sdk-generator, and create Swift SDKs for x86_64, aarch64, and armv7../scripts/vendor-boringssl.shscript to use these installed Swift SDKs to cross-compile for Linux architectures in the script.Result:
Swift SDKs are used to generate symbols for Linux architectures instead of Docker, and missing symbols for armv7 are added as well.
I have a few pros and cons for this solution:
Let me know what you think @Lukasa.