package/containerd: fix btrfs handling

btrfs handling doesn't depend on btrfs-progs but on kernel >= 4.12 since
bump to version 1.7.7 in commit 79e01ef950
and
024a748c09
resulting in the following build failure:

In file included from vendor/github.com/containerd/btrfs/v2/btrfs.go:21:0:
./btrfs.h:19:2: error: #error "Headers from kernel >= 4.12 are required on compilation time (not on run time)"
 #error "Headers from kernel >= 4.12 are required on compilation time (not on run time)"
  ^~~~~
In file included from vendor/github.com/containerd/btrfs/v2/btrfs.go:21:0:
./btrfs.h:22:10: fatal error: linux/btrfs_tree.h: No such file or directory
 #include <linux/btrfs_tree.h>
          ^~~~~~~~~~~~~~~~~~~~

Fixes: 79e01ef950
 - http://autobuild.buildroot.org/results/d6afeef47daae1783dcce3e2b6a0a16e3e5d5fbd

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This commit is contained in:
Fabrice Fontaine 2024-03-21 22:12:45 +01:00 committed by Peter Korsgaard
parent 752ab5a9e6
commit 43ca417c0c
2 changed files with 5 additions and 6 deletions

View File

@ -20,12 +20,13 @@ if BR2_PACKAGE_CONTAINERD
config BR2_PACKAGE_CONTAINERD_DRIVER_BTRFS
bool "btrfs snapshot driver"
depends on BR2_USE_MMU # btrfs-progs
depends on BR2_TOOLCHAIN_HAS_THREADS # btrfs-progs
select BR2_PACKAGE_BTRFS_PROGS
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_12
help
Build the btrfs snapshot driver for containerd.
comment "brtfs snapshot driver needs headers >= 4.12"
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_12
config BR2_PACKAGE_CONTAINERD_DRIVER_DEVMAPPER
bool "devmapper snapshot driver"
depends on BR2_TOOLCHAIN_HAS_THREADS # lvm2

View File

@ -35,9 +35,7 @@ CONTAINERD_DEPENDENCIES += libseccomp host-pkgconf
CONTAINERD_TAGS += seccomp
endif
ifeq ($(BR2_PACKAGE_CONTAINERD_DRIVER_BTRFS),y)
CONTAINERD_DEPENDENCIES += btrfs-progs
else
ifneq ($(BR2_PACKAGE_CONTAINERD_DRIVER_BTRFS),y)
CONTAINERD_TAGS += no_btrfs
endif