summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch')
-rw-r--r--meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch127
1 files changed, 0 insertions, 127 deletions
diff --git a/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch b/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch
deleted file mode 100644
index 0140633db..000000000
--- a/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch
+++ /dev/null
@@ -1,127 +0,0 @@
1Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/0d854db361106dfcb055231fd0112c5b85ef2287]
2
3Fix CVEs for opencv 3.3.
4
5* CVE-2017-12597
6* CVE-2017-12598
7* CVE-2017-12599
8* CVE-2017-12600
9* CVE-2017-12601
10* CVE-2017-12602
11* CVE-2017-12603
12* CVE-2017-12604
13* CVE-2017-12605
14* CVE-2017-12606
15* CVE-2017-12862
16* CVE-2017-12863
17* CVE-2017-12864
18
19Signed-off-by: Kai Kang <kai.kang@windriver.com>
20---
21From 0d854db361106dfcb055231fd0112c5b85ef2287 Mon Sep 17 00:00:00 2001
22From: Alexander Alekhin <alexander.a.alekhin@gmail.com>
23Date: Tue, 15 Aug 2017 21:45:05 +0000
24Subject: [PATCH 1/3] build: workaround GCC 7.1.1 compilation issue with
25 sanitize flags
26
27Version: gcc (GCC) 7.1.1 20170622 (Red Hat 7.1.1-3)
28Flags: -fsanitize=address,undefined
29---
30 modules/ts/src/cuda_test.cpp | 56 ++++++++++++++++++++++++++------------------
31 1 file changed, 33 insertions(+), 23 deletions(-)
32
33diff --git a/modules/ts/src/cuda_test.cpp b/modules/ts/src/cuda_test.cpp
34index a48e0a087..eb4cee136 100644
35--- a/modules/ts/src/cuda_test.cpp
36+++ b/modules/ts/src/cuda_test.cpp
37@@ -322,16 +322,20 @@ namespace cvtest
38
39 if (m1.size() != m2.size())
40 {
41- return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \""
42- << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \""
43- << expr2 << "\" [" << PrintToString(m2.size()) << "]";
44+ std::stringstream msg;
45+ msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \""
46+ << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \""
47+ << expr2 << "\" [" << PrintToString(m2.size()) << "]";
48+ return AssertionFailure() << msg.str();
49 }
50
51 if (m1.type() != m2.type())
52 {
53- return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \""
54- << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \""
55- << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]";
56+ std::stringstream msg;
57+ msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \""
58+ << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \""
59+ << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]";
60+ return AssertionFailure() << msg.str();
61 }
62
63 Mat diff;
64@@ -343,12 +347,14 @@ namespace cvtest
65
66 if (maxVal > eps)
67 {
68- return AssertionFailure() << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2
69- << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")"
70- << ", which exceeds \"" << eps_expr << "\", where \""
71- << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \""
72- << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \""
73- << eps_expr << "\" evaluates to " << eps;
74+ std::stringstream msg;
75+ msg << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2
76+ << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")"
77+ << ", which exceeds \"" << eps_expr << "\", where \""
78+ << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \""
79+ << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \""
80+ << eps_expr << "\" evaluates to " << eps;
81+ return AssertionFailure() << msg.str();
82 }
83
84 return AssertionSuccess();
85@@ -469,9 +475,11 @@ namespace cvtest
86 {
87 if (gold.size() != actual.size())
88 {
89- return testing::AssertionFailure() << "KeyPoints size mistmach\n"
90- << "\"" << gold_expr << "\" : " << gold.size() << "\n"
91- << "\"" << actual_expr << "\" : " << actual.size();
92+ std::stringstream msg;
93+ msg << "KeyPoints size mistmach\n"
94+ << "\"" << gold_expr << "\" : " << gold.size() << "\n"
95+ << "\"" << actual_expr << "\" : " << actual.size();
96+ return AssertionFailure() << msg.str();
97 }
98
99 std::sort(actual.begin(), actual.end(), KeyPointLess());
100@@ -484,14 +492,16 @@ namespace cvtest
101
102 if (!keyPointsEquals(p1, p2))
103 {
104- return testing::AssertionFailure() << "KeyPoints differ at " << i << "\n"
105- << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n"
106- << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n"
107- << "size : " << p1.size << " vs " << p2.size << "\n"
108- << "angle : " << p1.angle << " vs " << p2.angle << "\n"
109- << "response : " << p1.response << " vs " << p2.response << "\n"
110- << "octave : " << p1.octave << " vs " << p2.octave << "\n"
111- << "class_id : " << p1.class_id << " vs " << p2.class_id;
112+ std::stringstream msg;
113+ msg << "KeyPoints differ at " << i << "\n"
114+ << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n"
115+ << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n"
116+ << "size : " << p1.size << " vs " << p2.size << "\n"
117+ << "angle : " << p1.angle << " vs " << p2.angle << "\n"
118+ << "response : " << p1.response << " vs " << p2.response << "\n"
119+ << "octave : " << p1.octave << " vs " << p2.octave << "\n"
120+ << "class_id : " << p1.class_id << " vs " << p2.class_id;
121+ return AssertionFailure() << msg.str();
122 }
123 }
124
125--
1262.14.1
127