mirror of
git://git.yoctoproject.org/meta-virtualization.git
synced 2025-07-19 12:50:22 +02:00
podman-tui: fix build with btrfs-tools 6.1
We'd really prefer to bump the vendor SRCREV and allow the fetcher to bring in the pending change without needing a patch, but there are other API changes that trickle through the code. So we extract just the patch we need, and leave the SRCREV info in the recipe, to document the source. When the upstream updates its vendor/ directory, we can drop this (as the patch will no longer apply) Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
parent
0b9260ade5
commit
5b1e03f314
|
@ -0,0 +1,38 @@
|
|||
From 246ba3062e8b551026aef2708eee747014ce5c52 Mon Sep 17 00:00:00 2001
|
||||
From: Rui Chen <rui@chenrui.dev>
|
||||
Date: Wed, 28 Dec 2022 18:26:39 -0500
|
||||
Subject: [PATCH] fix: workaround field rename in btrfs-progs 6.1
|
||||
|
||||
same as kdave/btrfs-progs@0345143
|
||||
|
||||
Signed-off-by: Rui Chen <rui@chenrui.dev>
|
||||
---
|
||||
drivers/btrfs/btrfs.go | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/drivers/btrfs/btrfs.go b/drivers/btrfs/btrfs.go
|
||||
index e8b16b858..3d9053297 100644
|
||||
--- a/drivers/btrfs/btrfs.go
|
||||
+++ b/drivers/btrfs/btrfs.go
|
||||
@@ -6,6 +6,9 @@ package btrfs
|
||||
/*
|
||||
#include <stdlib.h>
|
||||
#include <dirent.h>
|
||||
+
|
||||
+// keep struct field name compatible with btrfs-progs < 6.1.
|
||||
+#define max_referenced max_rfer
|
||||
#include <btrfs/ioctl.h>
|
||||
#include <btrfs/ctree.h>
|
||||
|
||||
@@ -382,7 +385,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)))
|
||||
--
|
||||
2.34.1
|
||||
|
|
@ -17,10 +17,17 @@ DEPENDS = " \
|
|||
libgpg-error \
|
||||
"
|
||||
|
||||
SRCREV = "ab303cba7acabe340c5aa784ffb2a5dc3ab857d4"
|
||||
SRCREV_FORMAT = "podmantui_storage"
|
||||
SRCREV_podmantui = "ab303cba7acabe340c5aa784ffb2a5dc3ab857d4"
|
||||
SRCREV_storage = "246ba3062e8b551026aef2708eee747014ce5c52"
|
||||
SRC_URI = " \
|
||||
git://github.com/containers/podman-tui;protocol=https;branch=main \
|
||||
git://github.com/containers/podman-tui;protocol=https;name=podmantui;branch=main \
|
||||
"
|
||||
# Due to some other API changes, we can't directly import containers/storage at
|
||||
# the right commit, so we instead extract a patch and apply it to the tree
|
||||
#SRC_URI += "git://github.com/containers/storage;protocol=https;name=storage;branch=main;destsuffix=git/src/import/vendor/github.com/containers/storage"
|
||||
|
||||
SRC_URI += "file://0001-fix-workaround-field-rename-in-btrfs-progs-6.1.patch;patchdir=src/import/vendor/github.com/containers/storage"
|
||||
|
||||
LICENSE = "Apache-2.0"
|
||||
LIC_FILES_CHKSUM = "file://src/import/LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"
|
||||
|
|
Loading…
Reference in New Issue
Block a user