From c72ed92a2ff200eb8e6a4612a31d295e1d9aaa60 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Wed, 29 Jan 2025 16:25:15 +0100 Subject: [PATCH] Containerfile: build without cgo to avoid arm64 crashing This commit changes the build to not build with CGO. There is really no need to build with CGO, we only need it for the `crypt()` version in the images library. However since with the merge of https://github.com/osbuild/images/pull/1114 that is no longer an issue. --- Containerfile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Containerfile b/Containerfile index 927c54b..f54639f 100644 --- a/Containerfile +++ b/Containerfile @@ -6,7 +6,10 @@ COPY . /build WORKDIR /build # keep in sync with: # https://github.com/containers/podman/blob/2981262215f563461d449b9841741339f4d9a894/Makefile#L51 -RUN go build -tags "containers_image_openpgp exclude_graphdriver_btrfs exclude_graphdriver_devicemapper" ./cmd/image-builder +# disable cgo as +# a) gcc crashes on fedora41/arm64 regularly +# b) we don't really need it +RUN CGO_ENABLED=0 go build -tags "containers_image_openpgp exclude_graphdriver_btrfs exclude_graphdriver_devicemapper" ./cmd/image-builder FROM registry.fedoraproject.org/fedora:41