Add binary support for s390x#12127
Conversation
This commit changes the script in scripts/kokoro/release/build_linux.sh to allow building bazel binary on a s390x machine. To execute this script, the following command should work on a s390x machine: export RELEASE_NAME=3.5.0 ./scripts/kokoro/release/build_linux.sh
|
ping @philwo? |
|
Hi @laurentlb, thank you for the comment. I originally raised this PR hoping to get some advice. A few days later after this PR, Phillip replied in #11965 and give me some suggestions on the relevant information, and currently we are in discussion about s390x VM/hardware access. Best. |
|
@ruixin-bao FYI, I'm still working through internal matters regarding the ToS you sent me. I made some progress yesterday, will follow up soon. |
|
gentle ping @philwo, any updates? Thanks : ). |
1 similar comment
|
gentle ping @philwo, any updates? Thanks : ). |
|
Hi, sorry for the late reply. This is not the right script to modify to add s390x or other architecture support - I don't think we currently have an existing script for the purpose of building a release binary from a source tree, although I agree it would be nice to have. Personally I would recommend to move these steps into a blog post or community maintained s390x repo of some sort for now, as it's more likely that it will be found there by someone explicitly searching for how to build Bazel on s390x than this script. FYI, I also don't think scripts like this should ever make persistent modifications to the system, like running Let me know if you have any questions. By the way, I haven't forgotten about your kind offer to grant us access to the s390x VM, unfortunately it's currently not possible for me to follow this or similar architecture support side-projects (e.g. better FreeBSD support or Windows-on-ARM support or ...) due to priorities :( I promise to get back to it when we have some breathing room though! Cheers, |
|
As an example, I just found this repo for Bazel on Raspberry Pi: https://github.com/koenvervloesem/bazel-on-arm. I think this is a great example of a community maintained repository like I mentioned above and an especially well written README. |
No worries : ).
I see, thanks for the info.
Thanks for the suggestion, my colleague and I actually have something like that. We have drafted a build instruction for building bazel on s390x at https://github.com/linux-on-ibm-z/docs/wiki/Building-Bazel
Yeah I agree --- I was not sure if the implementation in this PR makes sense at the point of writing it.
Thank you for your kind words. No worries, take your time. Let me know if I can provide any help when you get back to this side project : ).
Best, |
|
@ruixin-bao It looks like https://github.com/linux-on-ibm-z/docs/wiki/Building-Bazel replaces the need for this PR. |
|
Hi @aiuto, thanks for commenting. The intention for this PR was to add / propose adding s390x binaries to the official binaries, similar to that of arm64. The provided official binaries will allow potential s390x users to easily access the built s390x binaries instead of building from scratch each time. https://github.com/linux-on-ibm-z/docs/wiki/Building-Bazel only provides the build instruction for building baze on s390xl. The build instruction is beneficial if people want to build from scratch, but could be time consuming. Thus, I think adding binary support for s390x to the official releases would still be beneficial, so I'm wondering if we should reopen this PR? (I don't think I have right to reopen this, unfortunately) Thanks. |
|
I think reopening this is @philwo's choice. He gave a very detailed opinion of the PR back on April 22. |
This patch changes the script in scripts/kokoro/release/build_linux.sh
to allow building bazel binary on a s390x machine. I've also executed this script on x86 to ensure no regressions.
To execute this script, the following command works on a s390x machine with this PR:
Lastly, this patch hopes to achieve a similar thing as #8833 to add Bazel binary for s390x architecture. Though I wasn't able to find too many relevant information on how this was done for arm architecture, so any pointers or guidance will be super helpful. Hardware/VM access can also be provided if needed. Happy to discuss and make changes. Thanks!