Allow using multiplatform images #137
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
These are the changes necessary to build both
linux/amd64andlinux/arm64docker images. This way we can provide not only images running on x86_64 but also aarch64. They run much faster on ARM based Mac and ARM based Linux systems.On the native platform (x86_64-linux or aarch64-linux) ruby configure script finds libz and libcrypt and makes use of it in libruby.
Disabling them per
ac_cv_*variables unifies cross builds and we can remove platform specific injection of-lzand-lcryptintomkmf.rb.The docker image for the x64-mingw-ucrt compiler
larskanis/mingw64-ucrtneeds to be rebuilt onlinux/arm64platform, so that both arm64 and amd64 are provided. Currently the image for platformlinux/amd64is used onlinux/arm64, which doesn't work.The rebuild fails on docker arm64 emulation with segmentation fault, but works flawlessly on a real arm64 device.
When it is rebuilt, the deb package versions have changed versions, which is adjusted below. So it makes sense to rebuild and push
larskanis/mingw64-ucrtjust before this PR is merged.I didn't test whether the image build on x86_64 with
docker buildxarm64 emulation works. Maybe they crash similar tomingw64-ucrt. In any case it's very slow. However I can build thelinux/arm64images locally and push them manually.Fixes #78