From a5da53a9657d8f9e7560ee28f479ec995db7b04e Mon Sep 17 00:00:00 2001 From: Miltiadis Kallianis Date: Mon, 19 Feb 2024 12:26:30 +0100 Subject: [PATCH] update docs based on review Move docs under "Building without a container". Check instead of setting env variable. Provide alternative approach. Signed-off-by: Miltiadis Kallianis --- install.md | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/install.md b/install.md index 5080d29b0b..cbc0555f50 100644 --- a/install.md +++ b/install.md @@ -122,15 +122,6 @@ Skopeo has not yet been packaged for Windows. There is an [open feature request](https://github.com/containers/skopeo/issues/715) and contributions are always welcome. -## GO ENV settings - -In order for the system libraries to get compiled during the build process make sure that ```CGO_ENABLED='1'```. - -```bash -go env -w CGO_ENABLED='1' -``` - - ## Container Images Skopeo container images are available at `quay.io/skopeo/stable:latest`. @@ -203,6 +194,12 @@ document generation can be skipped by passing `DISABLE_DOCS=1`: DISABLE_DOCS=1 make ``` +#### Additional prerequisites + +In order to dynamically link against system libraries and avoid compilation erros the ```CGO_ENABLED='1'``` flag must be enabled. You can easily check by ```go env | grep CGO_ENABLED```. + +An alternative would be to set the `BUILDTAGS=containers_image_openpgp` (this removes the dependency on `libgpgme` and its companion libraries). + ### Cross-compilation For cross-building skopeo, use the command `make bin/skopeo.OS.ARCH`, where OS represents