Add exclude_graphdriver_btrfs tag to avoid btrfs CGO dependency

This commit is contained in:
christophe-duc 2026-01-07 16:01:39 -04:00
parent d98a1010a2
commit 5a50175cdc
3 changed files with 7 additions and 4 deletions

View file

@ -63,7 +63,7 @@ jobs:
podman info podman info
- name: Run integration tests - name: Run integration tests
run: | run: |
go test -tags=integration,containers_image_openpgp -v ./pkg/commands/... go test -tags=integration,containers_image_openpgp,exclude_graphdriver_btrfs -v ./pkg/commands/...
build: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
env: env:
@ -85,10 +85,10 @@ jobs:
${{runner.os}}-go- ${{runner.os}}-go-
- name: Build linux binary - name: Build linux binary
run: | run: |
GOOS=linux go build -tags=containers_image_openpgp GOOS=linux go build -tags=containers_image_openpgp,exclude_graphdriver_btrfs
- name: Build darwin binary - name: Build darwin binary
run: | run: |
GOOS=darwin go build -tags=containers_image_openpgp GOOS=darwin go build -tags=containers_image_openpgp,exclude_graphdriver_btrfs
check-codebase: check-codebase:
runs-on: ubuntu-latest runs-on: ubuntu-latest
env: env:

View file

@ -9,6 +9,7 @@ builds:
- id: binary - id: binary
tags: tags:
- containers_image_openpgp - containers_image_openpgp
- exclude_graphdriver_btrfs
goos: goos:
- darwin - darwin
- linux - linux
@ -20,6 +21,7 @@ builds:
- id: snap - id: snap
tags: tags:
- containers_image_openpgp - containers_image_openpgp
- exclude_graphdriver_btrfs
goos: goos:
- linux - linux
goarch: goarch:

View file

@ -6,7 +6,8 @@ echo "" > coverage.txt
export GOFLAGS=-mod=vendor export GOFLAGS=-mod=vendor
# Use pure Go PGP implementation to avoid CGO dependency on gpgme # Use pure Go PGP implementation to avoid CGO dependency on gpgme
BUILD_TAGS="-tags=containers_image_openpgp" # Exclude btrfs driver to avoid CGO dependency on libbtrfs
BUILD_TAGS="-tags=containers_image_openpgp,exclude_graphdriver_btrfs"
use_go_test=false use_go_test=false
if command -v gotest; then if command -v gotest; then