From 320a3e07754fb21f7dbe65740de121a00e47388a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Wed, 16 Apr 2025 18:51:40 +0200 Subject: [PATCH 1/3] Don't require BUILDTAGS to be non-empty MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This removes a safety mechanism, but it's better than inventing a dummy tag value (both here and in c/image). Signed-off-by: Miloslav Trmač --- contrib/cirrus/runner.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/cirrus/runner.sh b/contrib/cirrus/runner.sh index bd6a40d8..a506e644 100755 --- a/contrib/cirrus/runner.sh +++ b/contrib/cirrus/runner.sh @@ -128,7 +128,7 @@ _run_system() { make test-system-local BUILDTAGS="$BUILDTAGS" } -req_env_vars SKOPEO_PATH BUILDTAGS +req_env_vars SKOPEO_PATH handler="_run_${1}" if [ "$(type -t $handler)" != "function" ]; then From 47bf2b4ef7668f3d68e7cc5f933e7547963faf13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Wed, 16 Apr 2025 18:26:54 +0200 Subject: [PATCH 2/3] Stop setting btrfs_noversion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit c/storage no longer uses this tag after https://github.com/containers/storage/pull/2308 . Signed-off-by: Miloslav Trmač --- .cirrus.yml | 4 ++-- Makefile | 2 +- hack/btrfs_tag.sh | 7 ------- rpm/skopeo.spec | 4 ++-- 4 files changed, 5 insertions(+), 12 deletions(-) delete mode 100755 hack/btrfs_tag.sh diff --git a/.cirrus.yml b/.cirrus.yml index 91e330b1..6139315d 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -62,7 +62,7 @@ doccheck_task: cpu: 4 memory: 8 env: - BUILDTAGS: &withopengpg 'btrfs_noversion libdm_no_deferred_remove containers_image_openpgp' + BUILDTAGS: &withopengpg 'libdm_no_deferred_remove containers_image_openpgp' script: | # TODO: Can't use 'runner.sh setup' inside container. However, # removing the pre-installed package is the only necessary step @@ -194,7 +194,7 @@ test_skopeo_task: matrix: - name: "Skopeo Test" # N/B: Name ref. by hack/get_fqin.sh env: - BUILDTAGS: 'btrfs_noversion libdm_no_deferred_remove' + BUILDTAGS: 'libdm_no_deferred_remove' - name: "Skopeo Test w/ opengpg" env: BUILDTAGS: *withopengpg diff --git a/Makefile b/Makefile index 6646534f..87f2f170 100644 --- a/Makefile +++ b/Makefile @@ -90,7 +90,7 @@ SKOPEO_LDFLAGS := -ldflags '-X main.gitCommit=${GIT_COMMIT} $(EXTRA_LDFLAGS)' MANPAGES_MD = $(wildcard docs/*.md) MANPAGES ?= $(MANPAGES_MD:%.md=%) -BTRFS_BUILD_TAG = $(shell hack/btrfs_tag.sh) $(shell hack/btrfs_installed_tag.sh) +BTRFS_BUILD_TAG = $(shell hack/btrfs_installed_tag.sh) LIBSUBID_BUILD_TAG = $(shell hack/libsubid_tag.sh) LOCAL_BUILD_TAGS = $(BTRFS_BUILD_TAG) $(LIBSUBID_BUILD_TAG) BUILDTAGS += $(LOCAL_BUILD_TAGS) diff --git a/hack/btrfs_tag.sh b/hack/btrfs_tag.sh deleted file mode 100755 index ea753d4d..00000000 --- a/hack/btrfs_tag.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/usr/bin/env bash -${CPP:-${CC:-cc} -E} ${CPPFLAGS} - > /dev/null 2> /dev/null << EOF -#include -EOF -if test $? -ne 0 ; then - echo btrfs_noversion -fi diff --git a/rpm/skopeo.spec b/rpm/skopeo.spec index 9b18a8c8..3a590d5c 100644 --- a/rpm/skopeo.spec +++ b/rpm/skopeo.spec @@ -120,9 +120,9 @@ export CGO_CFLAGS="$CGO_CFLAGS -m64 -mtune=generic -fcf-protection=full" BASEBUILDTAGS="$(hack/libsubid_tag.sh)" %if %{defined build_with_btrfs} -export BUILDTAGS="$BASEBUILDTAGS $(hack/btrfs_tag.sh) $(hack/btrfs_installed_tag.sh)" +export BUILDTAGS="$BASEBUILDTAGS $(hack/btrfs_installed_tag.sh)" %else -export BUILDTAGS="$BASEBUILDTAGS btrfs_noversion exclude_graphdriver_btrfs" +export BUILDTAGS="$BASEBUILDTAGS exclude_graphdriver_btrfs" %endif %if %{defined fips} From 5cf5a11e04fc9563b23b6109e9ea2c41d15a699a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Wed, 16 Apr 2025 18:29:00 +0200 Subject: [PATCH 3/3] Stop setting libdm_no_deferred_remove MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit No code is consuming this build tag, and it should have been removed in 8d04b4a9f6430434f67b1607fc17293a24be01bc . Signed-off-by: Miloslav Trmač --- .cirrus.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index 6139315d..b5cd9206 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -62,7 +62,7 @@ doccheck_task: cpu: 4 memory: 8 env: - BUILDTAGS: &withopengpg 'libdm_no_deferred_remove containers_image_openpgp' + BUILDTAGS: &withopengpg 'containers_image_openpgp' script: | # TODO: Can't use 'runner.sh setup' inside container. However, # removing the pre-installed package is the only necessary step @@ -194,7 +194,7 @@ test_skopeo_task: matrix: - name: "Skopeo Test" # N/B: Name ref. by hack/get_fqin.sh env: - BUILDTAGS: 'libdm_no_deferred_remove' + BUILDTAGS: '' - name: "Skopeo Test w/ opengpg" env: BUILDTAGS: *withopengpg