From 89ce07cbfb926372d17f8d16beb95e36407724da Mon Sep 17 00:00:00 2001 From: Thomas Moschny Date: Mar 19 2018 16:19:03 +0000 Subject: Update empty patch file with the real patch contents. --- diff --git a/botan2.spec b/botan2.spec index eb7cd4c..4dd9cb5 100644 --- a/botan2.spec +++ b/botan2.spec @@ -2,7 +2,7 @@ Name: botan2 Version: 2.4.0 -Release: 8%{?dist} +Release: 9%{?dist} Summary: Crypto and TLS for C++11 License: BSD @@ -144,6 +144,9 @@ LD_LIBRARY_PATH=%{buildroot}%{_libdir} ./botan-test %changelog +* Mon Mar 19 2018 Thomas Moschny - 2.4.0-9 +- Update empty patch file with the real patch contents. + * Sat Mar 17 2018 Thomas Moschny - 2.4.0-8 - Add patch to fix test suite failures on ppc64le (see gh#1498). - Add patch to fix test suite if SIMD instructions are not available (see gh#1495). diff --git a/fix-testsuite-on-non-SIMD-machines.patch b/fix-testsuite-on-non-SIMD-machines.patch index e69de29..73ed106 100644 --- a/fix-testsuite-on-non-SIMD-machines.patch +++ b/fix-testsuite-on-non-SIMD-machines.patch @@ -0,0 +1,45 @@ +From 4d5fa7a0f30d0d62341be8488c807ccf9fc4f308 Mon Sep 17 00:00:00 2001 +From: Jack Lloyd +Date: Sat, 17 Mar 2018 11:54:52 -0400 +Subject: [PATCH] Avoid calling run() on SIMD tests if SIMD instructions not + available. + +Problem is the same flag that enables the intrinsics also gives the +compiler a free hand to emit same instructions for everything including +function preambles. So on systems without SSE2/NEON/etc, even jumping +to the test briefly causes a crash because GCC emits SIMD instructions +for things other than our intrinsics. + +GH #1495 +--- + src/tests/test_runner.cpp | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/src/tests/test_runner.cpp b/src/tests/test_runner.cpp +index 321a1e1..65206b4 100644 +--- a/src/tests/test_runner.cpp ++++ b/src/tests/test_runner.cpp +@@ -10,6 +10,7 @@ + #include + #include + #include ++#include + + namespace Botan_Tests { + +@@ -249,7 +250,11 @@ size_t Test_Runner::run_tests(const std::vector& tests_to_run, + + try + { +- if(Test* test = Test::get_test(test_name)) ++ if(test_name == "simd_32" && Botan::CPUID::has_simd_32() == false) ++ { ++ results.push_back(Test::Result::Note(test_name, "SIMD not available on this platform")); ++ } ++ else if(Test* test = Test::get_test(test_name)) + { + std::vector test_results = test->run(); + results.insert(results.end(), test_results.begin(), test_results.end()); +-- +2.9.5 +