diff options
author | Peter Levine <plevine457@gmail.com> | 2018-09-13 20:39:00 -0400 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2018-09-22 09:07:09 +0200 |
commit | f526bd2a3316a2fe76b231f731d9e9da2cd6a464 (patch) | |
tree | 5628df5dd0270925bea76a8f974ed9cc402ec9f4 /dev-cpp/gtest | |
parent | dev-cpp/gtest: Don't use gtest-1.8.0-fix-doublefree.patch (diff) | |
download | gentoo-f526bd2a3316a2fe76b231f731d9e9da2cd6a464.tar.gz gentoo-f526bd2a3316a2fe76b231f731d9e9da2cd6a464.tar.bz2 gentoo-f526bd2a3316a2fe76b231f731d9e9da2cd6a464.zip |
dev-cpp/gtest: Update gtest-9999-fix-gcc6-undefined-behavior.patch
Package-Manager: Portage-2.3.49, Repoman-2.3.10
Diffstat (limited to 'dev-cpp/gtest')
-rw-r--r-- | dev-cpp/gtest/files/gtest-1.8.0-fix-gcc6-undefined-behavior.patch | 21 | ||||
-rw-r--r-- | dev-cpp/gtest/files/gtest-9999-fix-gcc6-undefined-behavior.patch | 14 | ||||
-rw-r--r-- | dev-cpp/gtest/gtest-1.8.0-r1.ebuild | 2 | ||||
-rw-r--r-- | dev-cpp/gtest/gtest-1.8.0.ebuild | 2 |
4 files changed, 28 insertions, 11 deletions
diff --git a/dev-cpp/gtest/files/gtest-1.8.0-fix-gcc6-undefined-behavior.patch b/dev-cpp/gtest/files/gtest-1.8.0-fix-gcc6-undefined-behavior.patch new file mode 100644 index 000000000000..eadfe6197389 --- /dev/null +++ b/dev-cpp/gtest/files/gtest-1.8.0-fix-gcc6-undefined-behavior.patch @@ -0,0 +1,21 @@ +Fix build with GCC 6 due to lifetime issues. + +--- a/googletest/src/gtest.cc ++++ b/googletest/src/gtest.cc +@@ -2654,10 +2654,12 @@ + test->Run(); + } + +- // Deletes the test object. +- impl->os_stack_trace_getter()->UponLeavingGTest(); +- internal::HandleExceptionsInMethodIfSupported( +- test, &Test::DeleteSelf_, "the test fixture's destructor"); ++ if (test != NULL) { ++ // Deletes the test object. ++ impl->os_stack_trace_getter()->UponLeavingGTest(); ++ internal::HandleExceptionsInMethodIfSupported( ++ test, &Test::DeleteSelf_, "the test fixture's destructor"); ++ } + + result_.set_elapsed_time(internal::GetTimeInMillis() - start); + diff --git a/dev-cpp/gtest/files/gtest-9999-fix-gcc6-undefined-behavior.patch b/dev-cpp/gtest/files/gtest-9999-fix-gcc6-undefined-behavior.patch index eadfe6197389..8dfed46d4585 100644 --- a/dev-cpp/gtest/files/gtest-9999-fix-gcc6-undefined-behavior.patch +++ b/dev-cpp/gtest/files/gtest-9999-fix-gcc6-undefined-behavior.patch @@ -2,19 +2,15 @@ Fix build with GCC 6 due to lifetime issues. --- a/googletest/src/gtest.cc +++ b/googletest/src/gtest.cc -@@ -2654,10 +2654,12 @@ +@@ -2693,10 +2693,12 @@ test->Run(); } -- // Deletes the test object. -- impl->os_stack_trace_getter()->UponLeavingGTest(); -- internal::HandleExceptionsInMethodIfSupported( -- test, &Test::DeleteSelf_, "the test fixture's destructor"); + if (test != NULL) { -+ // Deletes the test object. -+ impl->os_stack_trace_getter()->UponLeavingGTest(); -+ internal::HandleExceptionsInMethodIfSupported( -+ test, &Test::DeleteSelf_, "the test fixture's destructor"); + // Deletes the test object. + impl->os_stack_trace_getter()->UponLeavingGTest(); + internal::HandleExceptionsInMethodIfSupported( + test, &Test::DeleteSelf_, "the test fixture's destructor"); + } result_.set_elapsed_time(internal::GetTimeInMillis() - start); diff --git a/dev-cpp/gtest/gtest-1.8.0-r1.ebuild b/dev-cpp/gtest/gtest-1.8.0-r1.ebuild index 96cb8b936bfb..3fd0d1438bea 100644 --- a/dev-cpp/gtest/gtest-1.8.0-r1.ebuild +++ b/dev-cpp/gtest/gtest-1.8.0-r1.ebuild @@ -22,7 +22,7 @@ RDEPEND="!dev-cpp/gmock" PATCHES=( "${FILESDIR}"/${PN}-9999-fix-py-tests.patch - "${FILESDIR}"/${PN}-9999-fix-gcc6-undefined-behavior.patch + "${FILESDIR}"/${PN}-1.8.0-fix-gcc6-undefined-behavior.patch "${FILESDIR}"/${PN}-1.8.0-multilib-strict.patch "${FILESDIR}"/${PN}-1.8.0-increase-clone-stack-size.patch "${FILESDIR}"/${PN}-1.8.0-fix-doublefree.patch diff --git a/dev-cpp/gtest/gtest-1.8.0.ebuild b/dev-cpp/gtest/gtest-1.8.0.ebuild index 3dbd8e1a06d4..fec38c4bc247 100644 --- a/dev-cpp/gtest/gtest-1.8.0.ebuild +++ b/dev-cpp/gtest/gtest-1.8.0.ebuild @@ -22,7 +22,7 @@ RDEPEND="!dev-cpp/gmock" PATCHES=( "${FILESDIR}"/${PN}-9999-fix-py-tests.patch - "${FILESDIR}"/${PN}-9999-fix-gcc6-undefined-behavior.patch + "${FILESDIR}"/${PN}-1.8.0-fix-gcc6-undefined-behavior.patch "${FILESDIR}"/${PN}-1.8.0-multilib-strict.patch "${FILESDIR}"/${PN}-1.8.0-increase-clone-stack-size.patch ) |