Blame SOURCES/0017-Conditionalize-test-for-PR-libstdc-71181-on-__LIBSTD.patch

e88ed2
From 102adc148612b50a4e3f12a88871ddc47bfb469e Mon Sep 17 00:00:00 2001
e88ed2
From: David Malcolm <dmalcolm@redhat.com>
e88ed2
Date: Thu, 2 Sep 2021 17:17:50 -0400
e88ed2
Subject: [PATCH 17/17] Conditionalize test for PR libstdc++/71181 on
e88ed2
 __LIBSTDCXX_SO_VERSION >= 7
e88ed2
e88ed2
This test was added upstream 2016-06-20 as part of:
e88ed2
  re PR libstdc++/71181 (Reserving in unordered_map doesn't reserve enough)
e88ed2
    https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=29dbb034cb3199167a9d0aaed040733c72326eed
e88ed2
e88ed2
but fails when run in DTS against a system libstdc++.so from an older GCC.
e88ed2
---
e88ed2
 .../testsuite/23_containers/unordered_set/hash_policy/71181.cc | 3 +++
e88ed2
 1 file changed, 3 insertions(+)
e88ed2
e88ed2
diff --git a/libstdc++-v3/testsuite/23_containers/unordered_set/hash_policy/71181.cc b/libstdc++-v3/testsuite/23_containers/unordered_set/hash_policy/71181.cc
e88ed2
index 324d735b8..b2dcd0137 100644
e88ed2
--- a/libstdc++-v3/testsuite/23_containers/unordered_set/hash_policy/71181.cc
e88ed2
+++ b/libstdc++-v3/testsuite/23_containers/unordered_set/hash_policy/71181.cc
e88ed2
@@ -39,7 +39,10 @@ template<typename _USet>
e88ed2
 
e88ed2
 	us.insert(nb_insert);
e88ed2
 
e88ed2
+	// Fixed upstream in GCC 7
e88ed2
+#if __LIBSTDCXX_SO_VERSION >= 7
e88ed2
 	VERIFY( us.bucket_count() == bkts );
e88ed2
+#endif
e88ed2
       }
e88ed2
   }
e88ed2
 
e88ed2
-- 
e88ed2
2.31.1
e88ed2