From 2812d91eb0d5a1acdfaf6b6b05149b97e75adf08 Mon Sep 17 00:00:00 2001 From: Rudi Heitbaum Date: Sat, 4 May 2024 14:29:49 +0000 Subject: [PATCH] rapidjson: fix gcc-14 build ref: - https://github.com/Tencent/rapidjson (718/719) - https://github.com/xbmc/inputstream.adaptive (1548) --- ...iling-assignment-operator.-Fixed-718.patch | 25 +++++++++++++++++++ ...tly-disable-copy-assignment-operator.patch | 25 +++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 packages/devel/rapidjson/patches/rapidjson-0002-Removed-non-compiling-assignment-operator.-Fixed-718.patch create mode 100644 packages/devel/rapidjson/patches/rapidjson-0003-Explicitly-disable-copy-assignment-operator.patch diff --git a/packages/devel/rapidjson/patches/rapidjson-0002-Removed-non-compiling-assignment-operator.-Fixed-718.patch b/packages/devel/rapidjson/patches/rapidjson-0002-Removed-non-compiling-assignment-operator.-Fixed-718.patch new file mode 100644 index 0000000000..ab02199baf --- /dev/null +++ b/packages/devel/rapidjson/patches/rapidjson-0002-Removed-non-compiling-assignment-operator.-Fixed-718.patch @@ -0,0 +1,25 @@ +From 3b2441b87f99ab65f37b141a7b548ebadb607b96 Mon Sep 17 00:00:00 2001 +From: Janusz Chorko +Date: Fri, 26 Aug 2016 21:17:38 +0200 +Subject: [PATCH] Removed non-compiling assignment operator. Fixed #718 + +--- + include/rapidjson/document.h | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/include/rapidjson/document.h b/include/rapidjson/document.h +index e3e20dfb..b0f1f70b 100644 +--- a/include/rapidjson/document.h ++++ b/include/rapidjson/document.h +@@ -316,8 +316,6 @@ struct GenericStringRef { + + GenericStringRef(const GenericStringRef& rhs) : s(rhs.s), length(rhs.length) {} + +- GenericStringRef& operator=(const GenericStringRef& rhs) { s = rhs.s; length = rhs.length; } +- + //! implicit conversion to plain CharType pointer + operator const Ch *() const { return s; } + +-- +2.43.0 + diff --git a/packages/devel/rapidjson/patches/rapidjson-0003-Explicitly-disable-copy-assignment-operator.patch b/packages/devel/rapidjson/patches/rapidjson-0003-Explicitly-disable-copy-assignment-operator.patch new file mode 100644 index 0000000000..4a3670d376 --- /dev/null +++ b/packages/devel/rapidjson/patches/rapidjson-0003-Explicitly-disable-copy-assignment-operator.patch @@ -0,0 +1,25 @@ +From 862c39be371278a45a88d4d1d75164be57bb7e2d Mon Sep 17 00:00:00 2001 +From: Janusz Chorko +Date: Fri, 26 Aug 2016 21:26:50 +0200 +Subject: [PATCH] Explicitly disable copy assignment operator + +--- + include/rapidjson/document.h | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/include/rapidjson/document.h b/include/rapidjson/document.h +index b0f1f70b..19f5a6a5 100644 +--- a/include/rapidjson/document.h ++++ b/include/rapidjson/document.h +@@ -326,6 +326,8 @@ private: + //! Disallow construction from non-const array + template + GenericStringRef(CharType (&str)[N]) /* = delete */; ++ //! Copy assignment operator not permitted - immutable type ++ GenericStringRef& operator=(const GenericStringRef& rhs) /* = delete */; + }; + + //! Mark a character pointer as constant string +-- +2.43.0 +