diff options
author | Khem Raj <raj.khem@gmail.com> | 2018-12-27 15:15:16 -0800 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2019-01-02 10:28:18 -0800 |
commit | aa5cf52fd4b7ede275d437543d18c67e65f6f448 (patch) | |
tree | 0731abdcc3418f34f174fce2f1b5b6708d145efe /meta-oe/recipes-test | |
parent | f0ef6d4a16d68409f3bf3b32a694089f5abd5787 (diff) | |
download | meta-openembedded-aa5cf52fd4b7ede275d437543d18c67e65f6f448.tar.gz |
catch2: Replace the patch with upstreamable patch
Update to tip of master
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe/recipes-test')
-rw-r--r-- | meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch | 53 | ||||
-rw-r--r-- | meta-oe/recipes-test/catch2/catch2_2.5.0.bb | 4 |
2 files changed, 29 insertions, 28 deletions
diff --git a/meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch b/meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch index c3f5fc9ce..dc8a8915e 100644 --- a/meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch +++ b/meta-oe/recipes-test/catch2/catch2/0001-Remove-redundant-move.patch | |||
@@ -1,36 +1,37 @@ | |||
1 | From b2bd82a0c0d3d5dda588d12cc1672a03a9630784 Mon Sep 17 00:00:00 2001 | 1 | From 7d7428fd09d1bcee281f7b678df8fb71e9365b17 Mon Sep 17 00:00:00 2001 |
2 | From: Khem Raj <raj.khem@gmail.com> | 2 | From: =?UTF-8?q?Martin=20Ho=C5=99e=C5=88ovsk=C3=BD?= |
3 | Date: Mon, 17 Dec 2018 17:27:43 -0800 | 3 | <martin.horenovsky@gmail.com> |
4 | Subject: [PATCH] Remove redundant move | 4 | Date: Thu, 27 Dec 2018 16:08:04 +0100 |
5 | Subject: [PATCH] A different approach | ||
5 | 6 | ||
6 | fixes errors like below | ||
7 | |||
8 | /mnt/a/yoe/build/tmp/work/aarch64-yoe-linux-musl/catch2/2.5.0-r0/git/include/internal/catch_session.cpp:52:29: | ||
9 | error: redundant move in return statement [-Werror=redundant-move] | ||
10 | 52 | return std::move(multi); | ||
11 | | ~~~~~~~~~^~~~~~~ | ||
12 | /mnt/a/yoe/build/tmp/work/aarch64-yoe-linux-musl/catch2/2.5.0-r0/git/include/internal/catch_session.cpp:52:29: | ||
13 | note: remove 'std::move' call | ||
14 | |||
15 | Upstream-Status: Submitted [https://github.com/catchorg/Catch2/pull/1474] | ||
16 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
17 | --- | 7 | --- |
18 | include/internal/catch_session.cpp | 2 +- | 8 | include/internal/catch_session.cpp | 15 ++++++++++----- |
19 | 1 file changed, 1 insertion(+), 1 deletion(-) | 9 | 1 file changed, 10 insertions(+), 5 deletions(-) |
20 | 10 | ||
21 | diff --git a/include/internal/catch_session.cpp b/include/internal/catch_session.cpp | ||
22 | index 0920521c..b66d57ac 100644 | ||
23 | --- a/include/internal/catch_session.cpp | 11 | --- a/include/internal/catch_session.cpp |
24 | +++ b/include/internal/catch_session.cpp | 12 | +++ b/include/internal/catch_session.cpp |
25 | @@ -49,7 +49,7 @@ namespace Catch { | 13 | @@ -42,14 +42,20 @@ namespace Catch { |
26 | multi->addListener(listener->create(Catch::ReporterConfig(config))); | 14 | return createReporter(config->getReporterName(), config); |
15 | } | ||
16 | |||
17 | - auto multi = std::unique_ptr<ListeningReporter>(new ListeningReporter); | ||
18 | + // On older platforms, returning std::unique_ptr<ListeningReporter> | ||
19 | + // when the return type is std::unique_ptr<IStreamingReporter> | ||
20 | + // doesn't compile without a std::move call. However, this causes | ||
21 | + // a warning on newer platforms. Thus, we have to work around | ||
22 | + // it a bit and downcast the pointer manually. | ||
23 | + auto ret = std::unique_ptr<IStreamingReporter>(new ListeningReporter); | ||
24 | + auto& multi = static_cast<ListeningReporter&>(*ret); | ||
25 | |||
26 | auto const& listeners = Catch::getRegistryHub().getReporterRegistry().getListeners(); | ||
27 | for (auto const& listener : listeners) { | ||
28 | - multi->addListener(listener->create(Catch::ReporterConfig(config))); | ||
29 | + multi.addListener(listener->create(Catch::ReporterConfig(config))); | ||
27 | } | 30 | } |
28 | multi->addReporter(createReporter(config->getReporterName(), config)); | 31 | - multi->addReporter(createReporter(config->getReporterName(), config)); |
29 | - return std::move(multi); | 32 | - return std::move(multi); |
30 | + return multi; | 33 | + multi.addReporter(createReporter(config->getReporterName(), config)); |
34 | + return ret; | ||
31 | } | 35 | } |
32 | 36 | ||
33 | 37 | ||
34 | -- | ||
35 | 2.20.1 | ||
36 | |||
diff --git a/meta-oe/recipes-test/catch2/catch2_2.5.0.bb b/meta-oe/recipes-test/catch2/catch2_2.5.0.bb index 14a1ebe80..26149b31e 100644 --- a/meta-oe/recipes-test/catch2/catch2_2.5.0.bb +++ b/meta-oe/recipes-test/catch2/catch2_2.5.0.bb | |||
@@ -9,7 +9,8 @@ SRC_URI = "git://github.com/catchorg/Catch2.git \ | |||
9 | file://0001-Remove-redundant-move.patch \ | 9 | file://0001-Remove-redundant-move.patch \ |
10 | " | 10 | " |
11 | # v2.5.0 | 11 | # v2.5.0 |
12 | SRCREV = "6ccd467094973824d89efb16cbc553e279f79823" | 12 | #SRCREV = "6ccd467094973824d89efb16cbc553e279f79823" |
13 | SRCREV = "461843b1f02a4bf5c59db88ff201d2c56fabf3a4" | ||
13 | 14 | ||
14 | S = "${WORKDIR}/git" | 15 | S = "${WORKDIR}/git" |
15 | 16 | ||
@@ -23,4 +24,3 @@ do_install_append() { | |||
23 | # Header-only library | 24 | # Header-only library |
24 | RDEPENDS_${PN}-dev = "" | 25 | RDEPENDS_${PN}-dev = "" |
25 | RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})" | 26 | RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})" |
26 | |||