From 23be57a0fc19beb528b2320c8fc50b49af6b1e53 Mon Sep 17 00:00:00 2001 From: Simon Warta Date: Wed, 31 Jul 2024 13:48:46 +0200 Subject: [PATCH] Fixup builders 0100 --- builders/Dockerfile.alpine | 2 +- builders/Dockerfile.cross | 2 +- builders/README.md | 6 ++++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/builders/Dockerfile.alpine b/builders/Dockerfile.alpine index ec276a23..721eae7f 100644 --- a/builders/Dockerfile.alpine +++ b/builders/Dockerfile.alpine @@ -1,4 +1,4 @@ -FROM rust:1.77.0-alpine +FROM --platform=linux/amd64 rust:1.77.0-alpine RUN apk add --no-cache ca-certificates build-base diff --git a/builders/Dockerfile.cross b/builders/Dockerfile.cross index e4a31b40..c45c4459 100644 --- a/builders/Dockerfile.cross +++ b/builders/Dockerfile.cross @@ -1,4 +1,4 @@ -FROM rust:1.77.0-bullseye +FROM --platform=linux/amd64 rust:1.77.0-bullseye # Install build dependencies RUN apt-get update \ diff --git a/builders/README.md b/builders/README.md index a161fef7..a5a5f517 100644 --- a/builders/README.md +++ b/builders/README.md @@ -28,6 +28,7 @@ See those DockerHub repos for all available versions of the builder images. - Rename builder image from cosmwasm/go-ext-builder to cosmwasm/libwasmvm-builder - Replace CentOS with Debian image for GNU linux builds +- Build all images with `--platform=linux/amd64` to avoid accidental ARM builds **Version 0019:** @@ -131,8 +132,9 @@ See those DockerHub repos for all available versions of the builder images. ## Usage -Create a local docker image, capable of cross-compling linux and macos dynamic -libs: +Create the Docker images, capable of cross-compling Linux and MacOS dynamic +libs. As the builder images are all x86_64, it can be slow and memory intense to +do this on a different architecture: ```sh (cd builders && make docker-images)