diff --git a/srcpkgs/moby/patches/btrfs-progs-6.1.patch b/srcpkgs/moby/patches/btrfs-progs-6.1.patch new file mode 100644 index 00000000000..39d72bcad0f --- /dev/null +++ b/srcpkgs/moby/patches/btrfs-progs-6.1.patch @@ -0,0 +1,36 @@ +From ffbbe3d103b045c3f8ec5f74aa71b7a314fd57fe Mon Sep 17 00:00:00 2001 +From: Shengjing Zhu +Date: Thu, 29 Dec 2022 02:37:39 +0800 +Subject: [PATCH] daemon/graphdriver/btrfs: workaround field rename in + btrfs-progs 6.1 + +Closes: #44698 + +Signed-off-by: Shengjing Zhu +--- + daemon/graphdriver/btrfs/btrfs.go | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/daemon/graphdriver/btrfs/btrfs.go b/daemon/graphdriver/btrfs/btrfs.go +index 720f1ab0cd43..f2f6bf9e975b 100644 +--- a/daemon/graphdriver/btrfs/btrfs.go ++++ b/daemon/graphdriver/btrfs/btrfs.go +@@ -6,6 +6,9 @@ package btrfs // import "github.com/docker/docker/daemon/graphdriver/btrfs" + /* + #include + #include ++ ++// keep struct field name compatible with btrfs-progs < 6.1. ++#define max_referenced max_rfer + #include + #include + +@@ -395,7 +398,7 @@ func subvolLimitQgroup(path string, size uint64) error { + defer closeDir(dir) + + var args C.struct_btrfs_ioctl_qgroup_limit_args +- args.lim.max_referenced = C.__u64(size) ++ args.lim.max_rfer = C.__u64(size) + args.lim.flags = C.BTRFS_QGROUP_LIMIT_MAX_RFER + _, _, errno := unix.Syscall(unix.SYS_IOCTL, getDirFd(dir), C.BTRFS_IOC_QGROUP_LIMIT, + uintptr(unsafe.Pointer(&args))) diff --git a/srcpkgs/moby/template b/srcpkgs/moby/template index 4684986b5cc..fb262bb5bee 100644 --- a/srcpkgs/moby/template +++ b/srcpkgs/moby/template @@ -1,10 +1,10 @@ # Template file for 'moby' # should be kept in sync with docker-cli pkgname=moby -version=20.10.21 +version=20.10.22 revision=1 # libnetwork commit is mentioned in vendor.conf -_libnetwork_commit=0dde5c895075df6e3630e76f750a447cf63f4789 +_libnetwork_commit=dcdf8f176d1e13ad719e913e796fb698d846de98 create_wrksrc=yes build_style=go go_import_path="github.com/docker/docker" @@ -17,9 +17,10 @@ license="Apache-2.0" homepage="https://www.docker.com" distfiles="https://github.com/moby/moby/archive/v${version}.tar.gz>moby-$version.tar.gz https://github.com/moby/libnetwork/archive/$_libnetwork_commit.tar.gz>libnetwork-$_libnetwork_commit.tar.gz" -checksum="61f4c3a2d0426e1bbbda1b0e5dd33ec203776f7d99d1a61522c77c04c4ed09fe - 9b0d97166a34e01c467e8e14a23a568de1c7771b45a6d745d12be11acf376508" +checksum="ee0e2168e27ec87f1b0650e86af5d3e167a07fd2ff8c1ce3bb588f0b4f9a4658 + dbe30210e00fd4fcc63ade49ab3b00ba8fa5a1e90d34b92c1ecc25f8b78149ba" system_groups="docker" +patch_args="-Np1 --directory=moby-$version" _moby_builddir="moby-$version" _libnetwork_builddir="libnetwork-$_libnetwork_commit"