diff options
author | Isa <hi@f2k1.de> | 2023-05-16 22:57:39 +0200 |
---|---|---|
committer | Isa <hi@f2k1.de> | 2023-06-18 10:22:22 +0200 |
commit | 64bc856b5829cabc9a38513b47cba7d79e78f506 (patch) | |
tree | f8295701ae142d1326c32c77e949416ef636ed5a /pkgs/servers/nosql/mongodb | |
parent | ab4a501d1e2c2dc2d310b44e7bae32c5ea75ec44 (diff) |
mongodb-5_0: 5.0.7 -> 5.0.18
Diffstat (limited to 'pkgs/servers/nosql/mongodb')
-rw-r--r-- | pkgs/servers/nosql/mongodb/5.0.nix | 11 | ||||
-rw-r--r-- | pkgs/servers/nosql/mongodb/fix-build-with-boost-1.79-5_0-linux.patch | 90 |
2 files changed, 96 insertions, 5 deletions
diff --git a/pkgs/servers/nosql/mongodb/5.0.nix b/pkgs/servers/nosql/mongodb/5.0.nix index cd25525f4fe6e..ace169f828140 100644 --- a/pkgs/servers/nosql/mongodb/5.0.nix +++ b/pkgs/servers/nosql/mongodb/5.0.nix @@ -6,13 +6,15 @@ let }; variants = if stdenv.isLinux then { - version = "5.0.7"; - sha256 = "sha256-1PeDBZJNqJXHH/cSh2e+WR0PfS/b7XuJEzkkbrRT/gc="; + version = "5.0.18"; + sha256 = "sha256-tvQkDBwXYRZbIuST49JJ5T9zzYe/4BQ8ul1vUGlXHxI="; + patches = [ ./fix-build-with-boost-1.79-5_0-linux.patch ]; } - else + else lib.optionalAttrs stdenv.isDarwin { version = "5.0.3"; # at least darwin has to stay on 5.0.3 until the SDK used by nixpkgs is bumped to 10.13 sha256 = "1p9pq0dfd6lynvnz5p1c8dqp4filzrz86j840xwxwx82dm1zl6p0"; + patches = [ ./fix-build-with-boost-1.79-5_0.patch ]; # no darwin in name to prevent unnecessary rebuild }; in buildMongoDB { @@ -21,7 +23,6 @@ buildMongoDB { patches = [ ./forget-build-dependencies-4-4.patch ./asio-no-experimental-string-view-4-4.patch - ./fix-build-with-boost-1.79-5_0.patch ./fix-gcc-Wno-exceptions-5.0.patch - ]; + ] ++ variants.patches; } diff --git a/pkgs/servers/nosql/mongodb/fix-build-with-boost-1.79-5_0-linux.patch b/pkgs/servers/nosql/mongodb/fix-build-with-boost-1.79-5_0-linux.patch new file mode 100644 index 0000000000000..eb205bd92894a --- /dev/null +++ b/pkgs/servers/nosql/mongodb/fix-build-with-boost-1.79-5_0-linux.patch @@ -0,0 +1,90 @@ +From fb846bdbd07cc3b8ada6179dccd974072c2b69da Mon Sep 17 00:00:00 2001 +From: Et7f3 <cadeaudeelie@gmail.com> +Date: Tue, 19 Jul 2022 22:01:56 +0200 +Subject: [PATCH] build: Upgrade boost to 1.79.0 + +We can see in src/third_party/boost/boost/version.hpp that vendored version of +boost is BOOST_LIB_VERSION "1_76" + +We can also see the doc desbribe 2 headers to use filesystems lib: One is +src/third_party/boost/boost/filesystem/fstream.hpp that contains (175-177) + typedef basic_ifstream<char> ifstream; + typedef basic_ofstream<char> ofstream; + typedef basic_fstream<char> fstream; + +So this mean they mostly forgot to include a header and include-what-you-use +would catch this error. + +In upstream they fixed in a simmilar way +https://github.com/mongodb/mongo/commit/13389dc222fc372442be8c147e09685bb9a26a3a +--- + src/mongo/db/storage/storage_repair_observer.cpp | 1 + + src/mongo/db/storage/wiredtiger/wiredtiger_util.cpp | 1 + + src/mongo/shell/shell_utils_extended.cpp | 1 + + src/mongo/util/processinfo_linux.cpp | 1 + + src/mongo/util/stacktrace_threads.cpp | 1 + + 5 files changed, 5 insertions(+) + +diff --git a/src/mongo/db/storage/storage_repair_observer.cpp b/src/mongo/db/storage/storage_repair_observer.cpp +index 22b76a6a39c..453f48229cd 100644 +--- a/src/mongo/db/storage/storage_repair_observer.cpp ++++ b/src/mongo/db/storage/storage_repair_observer.cpp +@@ -42,6 +42,7 @@ + #endif + + #include <boost/filesystem/path.hpp> ++#include <boost/filesystem/fstream.hpp> + + #include "mongo/db/dbhelpers.h" + #include "mongo/db/operation_context.h" +diff --git a/src/mongo/db/storage/wiredtiger/wiredtiger_util.cpp b/src/mongo/db/storage/wiredtiger/wiredtiger_util.cpp +index 2f032e4..d1a90e0 100644 +--- a/src/mongo/db/storage/wiredtiger/wiredtiger_util.cpp ++++ b/src/mongo/db/storage/wiredtiger/wiredtiger_util.cpp +@@ -37,6 +37,7 @@ + + #include <boost/filesystem.hpp> + #include <boost/filesystem/path.hpp> ++#include <boost/filesystem/fstream.hpp> + #include <pcrecpp.h> + + #include "mongo/base/simple_string_data_comparator.h" +diff --git a/src/mongo/shell/shell_utils_extended.cpp b/src/mongo/shell/shell_utils_extended.cpp +index fbdddc1318d..e37d4c93a11 100644 +--- a/src/mongo/shell/shell_utils_extended.cpp ++++ b/src/mongo/shell/shell_utils_extended.cpp +@@ -37,6 +37,7 @@ + #endif + + #include <boost/filesystem.hpp> ++#include <boost/filesystem/fstream.hpp> + #include <fmt/format.h> + #include <fstream> + +diff --git a/src/mongo/util/processinfo_linux.cpp b/src/mongo/util/processinfo_linux.cpp +index eae0e9b7764..d5cd40f6039 100644 +--- a/src/mongo/util/processinfo_linux.cpp ++++ b/src/mongo/util/processinfo_linux.cpp +@@ -52,6 +52,7 @@ + #endif + + #include <boost/filesystem.hpp> ++#include <boost/filesystem/fstream.hpp> + #include <boost/none.hpp> + #include <boost/optional.hpp> + #include <fmt/format.h> +diff --git a/src/mongo/util/stacktrace_threads.cpp b/src/mongo/util/stacktrace_threads.cpp +index d2ee29d24b4..d485fa22367 100644 +--- a/src/mongo/util/stacktrace_threads.cpp ++++ b/src/mongo/util/stacktrace_threads.cpp +@@ -36,6 +36,7 @@ + #include <array> + #include <atomic> + #include <boost/filesystem.hpp> ++#include <boost/filesystem/fstream.hpp> + #include <cstdint> + #include <cstdlib> + #include <dirent.h> +-- +2.32.1 (Apple Git-133) + |