summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorZhirui Dai2024-05-06 02:38:33 -0700
committerZhirui Dai2024-05-06 02:38:33 -0700
commitc27600b0b6700ff059a299f3ae9bcc14ba401f5b (patch)
tree1c2d6f4ed2002222c93d2b9178faec84bbf88c99
parent58487ab0f8a916867f724341475f9ce1ca568ad9 (diff)
downloadaur-c27600b0b6700ff059a299f3ae9bcc14ba401f5b.tar.gz
update fmt-v10.patch
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD4
-rw-r--r--fmt-v10.patch119
3 files changed, 97 insertions, 30 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 737e68b72bbc..fac2d279f3a2 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = open3d
pkgdesc = A Modern Library for 3D Data Processing
pkgver = 0.18.0
- pkgrel = 7
+ pkgrel = 8
epoch = 1
url = http://www.open3d.org
arch = x86_64
@@ -40,7 +40,7 @@ pkgbase = open3d
source = open3d::git+https://github.com/isl-org/Open3D.git#commit=5c982c7b5edc76f899860e2594a950c5c23ec88f
source = fmt-v10.patch
sha256sums = SKIP
- sha256sums = 235a82931cee490a26bcd4a133ea787a4c5cd2da3f1c331225bbeb1f334e75ed
+ sha256sums = ab2dbd819f4d4613505d384707ca9cb7913b9603739b6f6590a3a3d978cbe56a
pkgname = open3d
depends = libc++abi
diff --git a/PKGBUILD b/PKGBUILD
index f3950b590e91..cf4c36b8b732 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,7 +5,7 @@
pkgbase=open3d
pkgname=( {,python-}open3d python-py3d )
pkgver=0.18.0
-pkgrel=7
+pkgrel=8
epoch=1
pkgdesc="A Modern Library for 3D Data Processing"
arch=('x86_64')
@@ -54,7 +54,7 @@ source=(
)
sha256sums=(
'SKIP'
- '235a82931cee490a26bcd4a133ea787a4c5cd2da3f1c331225bbeb1f334e75ed')
+ 'ab2dbd819f4d4613505d384707ca9cb7913b9603739b6f6590a3a3d978cbe56a')
function prepare() {
cd "${srcdir}/${pkgbase}"
diff --git a/fmt-v10.patch b/fmt-v10.patch
index 02986da215fb..fd1dfc77be0d 100644
--- a/fmt-v10.patch
+++ b/fmt-v10.patch
@@ -1,3 +1,27 @@
+diff --git a/3rdparty/fmt/fmt.cmake b/3rdparty/fmt/fmt.cmake
+index 88cd8e2fc..24dae557c 100644
+--- a/3rdparty/fmt/fmt.cmake
++++ b/3rdparty/fmt/fmt.cmake
+@@ -2,16 +2,16 @@ include(ExternalProject)
+
+ set(FMT_LIB_NAME fmt)
+
+-if (MSVC OR CMAKE_CXX_COMPILER_ID MATCHES "IntelLLVM")
++if (MSVC)
+ # MSVC has errors when building fmt >6, up till 9.1
+ # SYCL / DPC++ needs fmt ver <=6 or >= 9.2: https://github.com/fmtlib/fmt/issues/3005
+ set(FMT_VER "6.0.0")
+ set(FMT_SHA256
+ "f1907a58d5e86e6c382e51441d92ad9e23aea63827ba47fd647eacc0d3a16c78")
+ else()
+- set(FMT_VER "9.0.0")
++ set(FMT_VER "10.2.1")
+ set(FMT_SHA256
+- "9a1e0e9e843a356d65c7604e2c8bf9402b50fe294c355de0095ebd42fb9bd2c5")
++ "1250e4cc58bf06ee631567523f48848dc4596133e163f02615c97f78bab6c811")
+ endif()
+
+ ExternalProject_Add(
diff --git a/CHANGELOG.md b/CHANGELOG.md
index b68b0bdbd..9b0d48b1e 100644
--- a/CHANGELOG.md
@@ -11,10 +35,10 @@ index b68b0bdbd..9b0d48b1e 100644
## 0.13
diff --git a/cpp/open3d/core/DLPack.h b/cpp/open3d/core/DLPack.h
-index 9a0c3e57a..bf935b1ab 100644
+index 9a0c3e57a..1cec10a71 100644
--- a/cpp/open3d/core/DLPack.h
+++ b/cpp/open3d/core/DLPack.h
-@@ -188,4 +188,49 @@ typedef struct DLManagedTensor {
+@@ -188,4 +188,56 @@ typedef struct DLManagedTensor {
#ifdef __cplusplus
} // DLPACK_EXTERN_C
#endif
@@ -25,9 +49,11 @@ index 9a0c3e57a..bf935b1ab 100644
+namespace fmt {
+
+template <>
-+struct formatter<DLDeviceType> : formatter<string_view> {
-+ auto format(const DLDeviceType& c, format_context& ctx) const {
-+ string_view text;
++struct formatter<DLDeviceType> {
++ template <typename FormatContext>
++ auto format(const DLDeviceType& c, FormatContext& ctx) const
++ -> decltype(ctx.out()) {
++ const char* text = nullptr;
+ switch (c) {
+ case kDLCPU:
+ text = "kDLCPU";
@@ -57,18 +83,36 @@ index 9a0c3e57a..bf935b1ab 100644
+ text = "kDLExtDev";
+ break;
+ }
-+ return formatter<string_view>::format(text, ctx);
++ return format_to(ctx.out(), text);
++ }
++
++ template <typename ParseContext>
++ constexpr auto parse(ParseContext& ctx) -> decltype(ctx.begin()) {
++ return ctx.begin();
+ }
+};
+
+} // namespace fmt
+
#endif // DLPACK_DLPACK_H_
+diff --git a/cpp/open3d/io/IJsonConvertibleIO.h b/cpp/open3d/io/IJsonConvertibleIO.h
+index 8bc9f03b1..a366b4f5e 100644
+--- a/cpp/open3d/io/IJsonConvertibleIO.h
++++ b/cpp/open3d/io/IJsonConvertibleIO.h
+@@ -82,7 +82,7 @@ bool WriteIJsonConvertibleToJSONString(std::string &json_string,
+ [&str](const std::pair<ENUM_TYPE, std::string> &es_pair) \
+ -> bool { return es_pair.second == str; }); \
+ e = ((it != std::end(m)) ? it : std::begin(m))->first; \
+- utility::LogDebug("{} -> {}", str, e); \
++ utility::LogDebug("{} -> {}", str, enum_to_string(e)); \
+ }
+
+ } // namespace io
diff --git a/cpp/open3d/t/geometry/RaycastingScene.cpp b/cpp/open3d/t/geometry/RaycastingScene.cpp
-index 14f9962c2..0251c7922 100644
+index 14f9962c2..8906f6373 100644
--- a/cpp/open3d/t/geometry/RaycastingScene.cpp
+++ b/cpp/open3d/t/geometry/RaycastingScene.cpp
-@@ -1173,4 +1173,38 @@ uint32_t RaycastingScene::INVALID_ID() { return RTC_INVALID_GEOMETRY_ID; }
+@@ -1173,4 +1173,44 @@ uint32_t RaycastingScene::INVALID_ID() { return RTC_INVALID_GEOMETRY_ID; }
} // namespace geometry
} // namespace t
@@ -78,10 +122,10 @@ index 14f9962c2..0251c7922 100644
+
+namespace fmt {
+template <>
-+struct formatter<RTCError> : formatter<string_view> {
++struct formatter<RTCError> {
+ template <typename FormatContext>
+ auto format(const RTCError& c, FormatContext& ctx) {
-+ string_view name;
++ const char* name = nullptr;
+ switch (c) {
+ case RTC_ERROR_NONE:
+ name = "RTC_ERROR_NONE";
@@ -105,15 +149,33 @@ index 14f9962c2..0251c7922 100644
+ name = "RTC_ERROR_CANCELLED";
+ break;
+ }
-+ return formatter<string_view>::format(name, ctx);
++ // return formatter<string_view>::format(name, ctx);
++ return format_to(ctx.out(), name);
++ }
++
++ template <typename ParseContext>
++ constexpr auto parse(ParseContext& ctx) -> decltype(ctx.begin()) {
++ return ctx.begin();
+ }
+};
+} // namespace fmt
+diff --git a/cpp/open3d/t/io/sensor/realsense/RSBagReader.cpp b/cpp/open3d/t/io/sensor/realsense/RSBagReader.cpp
+index 356fdbed6..990b948ee 100644
+--- a/cpp/open3d/t/io/sensor/realsense/RSBagReader.cpp
++++ b/cpp/open3d/t/io/sensor/realsense/RSBagReader.cpp
+@@ -7,6 +7,7 @@
+
+ #include "open3d/t/io/sensor/realsense/RSBagReader.h"
+
++#include <fmt/std.h>
+ #include <json/json.h>
+
+ #include <chrono>
diff --git a/cpp/open3d/visualization/webrtc_server/PeerConnectionManager.h b/cpp/open3d/visualization/webrtc_server/PeerConnectionManager.h
-index ceb0fc9df..b28e77e37 100644
+index ceb0fc9df..8ef27e79a 100644
--- a/cpp/open3d/visualization/webrtc_server/PeerConnectionManager.h
+++ b/cpp/open3d/visualization/webrtc_server/PeerConnectionManager.h
-@@ -456,3 +456,41 @@ protected:
+@@ -456,3 +456,45 @@ protected:
} // namespace webrtc_server
} // namespace visualization
} // namespace open3d
@@ -121,10 +183,10 @@ index ceb0fc9df..b28e77e37 100644
+namespace fmt {
+
+template <>
-+struct formatter<webrtc::PeerConnectionInterface::SignalingState>
-+ : formatter<string_view> {
++struct formatter<webrtc::PeerConnectionInterface::SignalingState> {
++ template <typename FormatContext>
+ auto format(const webrtc::PeerConnectionInterface::SignalingState& state,
-+ format_context& ctx) const {
++ FormatContext& ctx) const -> decltype(ctx.out()) {
+ using namespace webrtc;
+ const char* text = nullptr;
+ switch (state) {
@@ -140,30 +202,35 @@ index ceb0fc9df..b28e77e37 100644
+ case PeerConnectionInterface::SignalingState::kHaveRemoteOffer:
+ text = "kHaveRemoteOffer";
+ break;
-+ case webrtc::PeerConnectionInterface::SignalingState::
-+ kHaveRemotePrAnswer:
++ case PeerConnectionInterface::SignalingState::kHaveRemotePrAnswer:
+ text = "kHaveRemotePrAnswer";
+ break;
-+ case webrtc::PeerConnectionInterface::SignalingState::kClosed:
++ case PeerConnectionInterface::SignalingState::kClosed:
+ text = "kClosed";
+ break;
+ default:
+ text = "unknown";
+ }
-+ return formatter<string_view>::format(text, ctx);
++ return format_to(ctx.out(), "{}", text);
++ }
++
++ template <typename ParseContext>
++ constexpr auto parse(ParseContext& ctx) -> decltype(ctx.begin()) {
++ return ctx.begin();
+ }
+};
+
+} // namespace fmt
diff --git a/examples/cpp/OnlineSLAMUtil.h b/examples/cpp/OnlineSLAMUtil.h
-index 585f18a8f..d1ea43e44 100644
+index 585f18a8f..ecb2d0b52 100644
--- a/examples/cpp/OnlineSLAMUtil.h
+++ b/examples/cpp/OnlineSLAMUtil.h
-@@ -8,6 +8,7 @@
+@@ -5,6 +5,8 @@
+ // SPDX-License-Identifier: MIT
+ // ----------------------------------------------------------------------------
+
++#include <fmt/std.h>
++
#include <atomic>
#include <sstream>
#include <thread>
-+#include <fmt/std.h>
-
- #include "open3d/Open3D.h"
-