summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Fore <csfore@posteo.net>2024-01-23 23:24:19 -0500
committerSam James <sam@gentoo.org>2024-01-24 07:30:27 +0000
commit1b57acdd9fe27f7d3f8b41665a52be59146d9e8e (patch)
tree7c14155312791a17551c96bc8f75c423dd104e72 /sys-fs/bcachefs-tools
parentprofiles/features/musl: fix mask entry (diff)
downloadgentoo-1b57acdd9fe27f7d3f8b41665a52be59146d9e8e.tar.gz
gentoo-1b57acdd9fe27f7d3f8b41665a52be59146d9e8e.tar.bz2
gentoo-1b57acdd9fe27f7d3f8b41665a52be59146d9e8e.zip
sys-fs/bcachefs-tools: fix musl+clang build failure on 1.4.0
- fix-clang-musl.patch Applies fix from upstream to rearrange the variable order All tests pass on glibc and musl. Closes: https://bugs.gentoo.org/921564 Signed-off-by: Christopher Fore <csfore@posteo.net> Closes: https://github.com/gentoo/gentoo/pull/34983 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-fs/bcachefs-tools')
-rw-r--r--sys-fs/bcachefs-tools/bcachefs-tools-1.4.0.ebuild4
-rw-r--r--sys-fs/bcachefs-tools/files/bcachefs-tools-1.4.0-fix-clang-musl.patch24
2 files changed, 28 insertions, 0 deletions
diff --git a/sys-fs/bcachefs-tools/bcachefs-tools-1.4.0.ebuild b/sys-fs/bcachefs-tools/bcachefs-tools-1.4.0.ebuild
index ab8af97606ec..a2e67f190904 100644
--- a/sys-fs/bcachefs-tools/bcachefs-tools-1.4.0.ebuild
+++ b/sys-fs/bcachefs-tools/bcachefs-tools-1.4.0.ebuild
@@ -160,6 +160,10 @@ BDEPEND="
virtual/rust
"
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.4.0-fix-clang-musl.patch
+)
+
llvm_check_deps() {
has_version -b "sys-devel/clang:${LLVM_SLOT}"
}
diff --git a/sys-fs/bcachefs-tools/files/bcachefs-tools-1.4.0-fix-clang-musl.patch b/sys-fs/bcachefs-tools/files/bcachefs-tools-1.4.0-fix-clang-musl.patch
new file mode 100644
index 000000000000..b011ca1de422
--- /dev/null
+++ b/sys-fs/bcachefs-tools/files/bcachefs-tools-1.4.0-fix-clang-musl.patch
@@ -0,0 +1,24 @@
+Bug: https://bugs.gentoo.org/921564
+From https://github.com/koverstreet/bcachefs-tools/commit/8e56da27fd23c169395b3b266b15a1c093aba849
+
+diff --git a/libbcachefs.c b/libbcachefs.c
+index 68b750a..ec6b272 100644
+--- a/libbcachefs.c
++++ b/libbcachefs.c
+@@ -445,6 +445,7 @@ struct bchfs_handle bcache_fs_open(const char *path)
+ */
+ struct bchfs_handle bchu_fs_open_by_dev(const char *path, int *idx)
+ {
++ struct bch_opts opts = bch2_opts_empty();
+ char buf[1024], *uuid_str;
+
+ struct stat stat = xstat(path);
+@@ -469,8 +470,6 @@ struct bchfs_handle bchu_fs_open_by_dev(const char *path, int *idx)
+ uuid_str = p + 1;
+ } else {
+ read_super:
+- struct bch_opts opts = bch2_opts_empty();
+-
+ opt_set(opts, noexcl, true);
+ opt_set(opts, nochanges, true);
+