package/gtest: needs gcc >= 5

Commit be38432532 wrongly assumed that
is_trivially_copy_constructible was available since gcc 4.9 but it
wasn't fully available until gcc 5.1 and
f5e523b76d
resulting in the following build failure with gcc 4.9.1:

In file included from /nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/include/gtest/internal/gtest-death-test-internal.h:39:0,
                 from /nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/include/gtest/gtest-death-test.h:41,
                 from /nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/include/gtest/gtest.h:64,
                 from /nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/src/gtest-all.cc:38:
/nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/include/gtest/gtest-matchers.h: In static member function 'static constexpr bool testing::internal::MatcherBase<T>::IsInlined()':
/nvmedata/autobuild/instance-13/output-1/build/gtest-1.11.0/googletest/include/gtest/gtest-matchers.h:414:12: error: 'is_trivially_copy_constructible' is not a member of 'std'
            std::is_trivially_copy_constructible<M>::value &&
            ^

Fixes:
 - http://autobuild.buildroot.org/results/1723705cb7aea5f6fcc7e6722d866ed3bd098115

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
(cherry picked from commit 3dd5b65681)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This commit is contained in:
Fabrice Fontaine
2022-06-10 18:54:12 +02:00
committed by Peter Korsgaard
parent 7f77ffcced
commit b3067072b9
2 changed files with 9 additions and 11 deletions

View File

@@ -3,7 +3,7 @@ config BR2_PACKAGE_GTEST
depends on BR2_USE_WCHAR depends on BR2_USE_WCHAR
depends on BR2_TOOLCHAIN_HAS_THREADS depends on BR2_TOOLCHAIN_HAS_THREADS
depends on BR2_INSTALL_LIBSTDCPP depends on BR2_INSTALL_LIBSTDCPP
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # C++11 depends on BR2_TOOLCHAIN_GCC_AT_LEAST_5 # C++11
depends on BR2_USE_MMU # fork() depends on BR2_USE_MMU # fork()
help help
Google's framework for writing C++ tests on a variety of Google's framework for writing C++ tests on a variety of
@@ -26,7 +26,7 @@ if BR2_PACKAGE_GTEST
config BR2_PACKAGE_GTEST_GMOCK config BR2_PACKAGE_GTEST_GMOCK
bool "gmock" bool "gmock"
depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-gtest depends on BR2_HOST_GCC_AT_LEAST_5 # host-gtest
help help
Inspired by jMock, EasyMock, and Hamcrest, and designed with Inspired by jMock, EasyMock, and Hamcrest, and designed with
C++'s specifics in mind, Google C++ Mocking Framework (or C++'s specifics in mind, Google C++ Mocking Framework (or
@@ -48,13 +48,12 @@ config BR2_PACKAGE_GTEST_GMOCK
libraries required to link/run them. The host package installs libraries required to link/run them. The host package installs
gmock_gen, a Python script used to generate code mocks. gmock_gen, a Python script used to generate code mocks.
comment "gmock needs host gcc >= 4.9" comment "gmock needs host gcc >= 5"
depends on !BR2_HOST_GCC_AT_LEAST_4_9 depends on !BR2_HOST_GCC_AT_LEAST_5
endif # BR2_PACKAGE_GTEST endif # BR2_PACKAGE_GTEST
comment "gtest needs a toolchain w/ C++, wchar, threads, gcc >= 4.9" comment "gtest needs a toolchain w/ C++, wchar, threads, gcc >= 5"
depends on BR2_USE_MMU depends on BR2_USE_MMU
depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \ depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \
!BR2_INSTALL_LIBSTDCPP || \ !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_GCC_AT_LEAST_5
!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9

View File

@@ -77,18 +77,17 @@ config BR2_PACKAGE_LIBCAMERA_COMPLIANCE
depends on BR2_USE_WCHAR # gtest depends on BR2_USE_WCHAR # gtest
depends on BR2_TOOLCHAIN_HAS_THREADS # gtest depends on BR2_TOOLCHAIN_HAS_THREADS # gtest
depends on BR2_INSTALL_LIBSTDCPP # gtest depends on BR2_INSTALL_LIBSTDCPP # gtest
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # gtest depends on BR2_TOOLCHAIN_GCC_AT_LEAST_5 # gtest
depends on BR2_USE_MMU # gtest depends on BR2_USE_MMU # gtest
select BR2_PACKAGE_GTEST select BR2_PACKAGE_GTEST
select BR2_PACKAGE_LIBEVENT select BR2_PACKAGE_LIBEVENT
help help
lc-compliance test application lc-compliance test application
comment "lc-compliance test application needs a toolchain w/ C++, wchar, threads, gcc >= 4.9" comment "lc-compliance test application needs a toolchain w/ C++, wchar, threads, gcc >= 5"
depends on BR2_USE_MMU depends on BR2_USE_MMU
depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \ depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS || \
!BR2_INSTALL_LIBSTDCPP || \ !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_GCC_AT_LEAST_5
!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
endif # BR2_PACKAGE_LIBCAMERA endif # BR2_PACKAGE_LIBCAMERA