summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfred Wingate <parona@protonmail.com>2024-08-19 21:28:49 +0300
committerSam James <sam@gentoo.org>2024-08-25 17:08:23 +0100
commit3eb644344c81572ed7a50f6e7a9c10db689dcd2c (patch)
tree9a3cb822fac397bf31e278e5866b1f1e3ae060f9 /sci-libs/caffe2
parentmedia-tv/kodi: update live (diff)
downloadgentoo-3eb644344c81572ed7a50f6e7a9c10db689dcd2c.tar.gz
gentoo-3eb644344c81572ed7a50f6e7a9c10db689dcd2c.tar.bz2
gentoo-3eb644344c81572ed7a50f6e7a9c10db689dcd2c.zip
sci-libs/caffe2: fix build against libfmt-11
Signed-off-by: Alfred Wingate <parona@protonmail.com> Closes: https://github.com/gentoo/gentoo/pull/38210 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sci-libs/caffe2')
-rw-r--r--sci-libs/caffe2/caffe2-2.4.0.ebuild1
-rw-r--r--sci-libs/caffe2/files/caffe2-2.4.0-libfmt-11.patch44
2 files changed, 45 insertions, 0 deletions
diff --git a/sci-libs/caffe2/caffe2-2.4.0.ebuild b/sci-libs/caffe2/caffe2-2.4.0.ebuild
index 524dafcaacef..81a8906ea669 100644
--- a/sci-libs/caffe2/caffe2-2.4.0.ebuild
+++ b/sci-libs/caffe2/caffe2-2.4.0.ebuild
@@ -121,6 +121,7 @@ PATCHES=(
../patches/${PN}-2.4.0-exclude-aotriton.patch
../patches/${PN}-2.3.0-fix-rocm-gcc14-clamp.patch
../patches/${PN}-2.3.0-fix-libcpp.patch
+ "${FILESDIR}"/${PN}-2.4.0-libfmt-11.patch
)
src_prepare() {
diff --git a/sci-libs/caffe2/files/caffe2-2.4.0-libfmt-11.patch b/sci-libs/caffe2/files/caffe2-2.4.0-libfmt-11.patch
new file mode 100644
index 000000000000..9f6740a07f1f
--- /dev/null
+++ b/sci-libs/caffe2/files/caffe2-2.4.0-libfmt-11.patch
@@ -0,0 +1,44 @@
+Fix build against libfmt-11
+
+https://github.com/pytorch/pytorch/commit/83eedf66b9e7f52323d9f45c5dfaa64472452595
+https://github.com/pytorch/pytorch/pull/130628
+
+From 83eedf66b9e7f52323d9f45c5dfaa64472452595 Mon Sep 17 00:00:00 2001
+From: Aaron Gokaslan <aaronGokaslan@gmail.com>
+Date: Tue, 16 Jul 2024 06:12:08 +0000
+Subject: [PATCH] Update libfmt submodule to 11.0.1 (#130628)
+
+Update libfmt to 11.0.1 reopen of https://github.com/pytorch/pytorch/pull/129962. Requires a kineto update and moves fmt::join into a separate include so added it where necessary.
+
+Pull Request resolved: https://github.com/pytorch/pytorch/pull/130628
+Approved by: https://github.com/aaronenyeshi
+--- a/torch/csrc/distributed/c10d/socket.cpp
++++ b/torch/csrc/distributed/c10d/socket.cpp
+@@ -32,6 +32,7 @@ C10_DIAGNOSTIC_PUSH_AND_IGNORED_IF_DEFINED("-Wdeprecated")
+ #include <fmt/chrono.h>
+ C10_DIAGNOSTIC_POP()
+ #include <fmt/format.h>
++#include <fmt/ranges.h>
+
+ #include <torch/csrc/distributed/c10d/error.h>
+ #include <torch/csrc/distributed/c10d/exception.h>
+--- a/torch/csrc/profiler/standalone/execution_trace_observer.cpp
++++ b/torch/csrc/profiler/standalone/execution_trace_observer.cpp
+@@ -10,6 +10,7 @@
+ #endif // _WIN32
+
+ #include <fmt/format.h>
++#include <fmt/ranges.h>
+ #include <chrono>
+ #include <cmath>
+ #include <fstream>
+--- a/torch/csrc/profiler/util.cpp
++++ b/torch/csrc/profiler/util.cpp
+@@ -5,6 +5,7 @@
+ #include <c10/util/ArrayRef.h>
+ #include <c10/util/irange.h>
+ #include <fmt/format.h>
++#include <fmt/ranges.h>
+
+ #ifdef USE_KINETO
+ #include <libkineto.h>