-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[build] Build sourcekit-lsp for multiple arches and lipo them #76730
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
@swift-ci Please test |
@swift-ci Please build toolchain |
Instead of building SourceKit-LSP using SwiftPM's multi-arch xcbuild backend, build it for only one arch at a time and then run `lipo` to merge the two resulting binaries. This should allow us to share build products between building installing and testing and also eliminates other quirks resulting from the xcbuild backend.
Toolchain builds succeeded. Just fixing Python lint issues now, so won’t run another toolchain build. |
44eb5ec
to
04e78e0
Compare
@swift-ci Please smoke test |
self.source_dir, 'Utilities', 'build-script-helper.py') | ||
|
||
install_destdir = self.host_install_destdir(host_target) | ||
toolchain_path = self.native_toolchain_path(base_target) |
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.
base_target
parameter is only used for this. I'm not really sure what's the semantics of native_toolchain_path
argument. Deferring to @edymtt .
Also, I think
# base_target is the machine that's driving the build.
is only true for Darwin platforms. For other platforms, build
/install
is called for each host. Should we use self.arg.host_target
instead?
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 think this looks fine. Correct me if I'm wrong, but the lipo takes place outside of the individual products. Correct?
Yes, that’s done by |
Instead of building SourceKit-LSP using SwiftPM's multi-arch xcbuild backend, build it for only one arch at a time and then run
lipo
to merge the two resulting binaries.This should allow us to share build products between building installing and testing and also eliminates other quirks resulting from the xcbuild backend.