diff options
author | tnn <tnn@pkgsrc.org> | 2022-04-25 13:58:46 +0000 |
---|---|---|
committer | tnn <tnn@pkgsrc.org> | 2022-04-25 13:58:46 +0000 |
commit | 23f0b65388febe8f93615ae728e90e248afab09a (patch) | |
tree | b97f359ed675bca850d2572100fe2d7893975f47 /security | |
parent | 3be595258bd59bb79913e056b23952c50096375a (diff) | |
download | pkgsrc-23f0b65388febe8f93615ae728e90e248afab09a.tar.gz |
olm: avoid ambiguous math functions
Diffstat (limited to 'security')
-rw-r--r-- | security/olm/distinfo | 3 | ||||
-rw-r--r-- | security/olm/patches/patch-tests_include_doctest.h | 19 |
2 files changed, 21 insertions, 1 deletions
diff --git a/security/olm/distinfo b/security/olm/distinfo index 97078ed5377..d8c44c8c806 100644 --- a/security/olm/distinfo +++ b/security/olm/distinfo @@ -1,5 +1,6 @@ -$NetBSD: distinfo,v 1.5 2022/01/25 12:55:43 ryoon Exp $ +$NetBSD: distinfo,v 1.6 2022/04/25 13:58:46 tnn Exp $ BLAKE2s (olm-3.2.10.tar.bz2) = 84c6a275ef0dda8371152f198ea0559d2531f51509a152223b148698d1b722c8 SHA512 (olm-3.2.10.tar.bz2) = 127a81f8585550fb59b922e656b877251fbc96b5b61629a9faaf10b82c88c28f5036de815803c654d9d82c436c75e11dd3b96c6a6cb14d4ae686b24ce3dcff94 Size (olm-3.2.10.tar.bz2) = 2733952 bytes +SHA1 (patch-tests_include_doctest.h) = d0da2f52ce14c454bc644e37fae238fab79e1c10 diff --git a/security/olm/patches/patch-tests_include_doctest.h b/security/olm/patches/patch-tests_include_doctest.h new file mode 100644 index 00000000000..53e6d567900 --- /dev/null +++ b/security/olm/patches/patch-tests_include_doctest.h @@ -0,0 +1,19 @@ +$NetBSD: patch-tests_include_doctest.h,v 1.1 2022/04/25 13:58:46 tnn Exp $ + +avoid ambigous call to std::log10. + +--- tests/include/doctest.h.orig 2022-01-10 10:00:49.000000000 +0000 ++++ tests/include/doctest.h +@@ -5914,9 +5914,9 @@ namespace { + separator_to_stream(); + s << std::dec; + +- auto totwidth = int(std::ceil(log10((std::max(p.numTestCasesPassingFilters, static_cast<unsigned>(p.numAsserts))) + 1))); +- auto passwidth = int(std::ceil(log10((std::max(p.numTestCasesPassingFilters - p.numTestCasesFailed, static_cast<unsigned>(p.numAsserts - p.numAssertsFailed))) + 1))); +- auto failwidth = int(std::ceil(log10((std::max(p.numTestCasesFailed, static_cast<unsigned>(p.numAssertsFailed))) + 1))); ++ auto totwidth = int(std::ceil(std::log10((std::max(p.numTestCasesPassingFilters, static_cast<unsigned>(p.numAsserts))) + 1))); ++ auto passwidth = int(std::ceil(std::log10((std::max(p.numTestCasesPassingFilters - p.numTestCasesFailed, static_cast<unsigned>(p.numAsserts - p.numAssertsFailed))) + 1))); ++ auto failwidth = int(std::ceil(std::log10((std::max(p.numTestCasesFailed, static_cast<unsigned>(p.numAssertsFailed))) + 1))); + const bool anythingFailed = p.numTestCasesFailed > 0 || p.numAssertsFailed > 0; + s << Color::Cyan << "[doctest] " << Color::None << "test cases: " << std::setw(totwidth) + << p.numTestCasesPassingFilters << " | " |