All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9
@ 2022-05-30 20:47 Fabrice Fontaine
  2022-05-30 20:47 ` [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks Fabrice Fontaine
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Fabrice Fontaine @ 2022-05-30 20:47 UTC (permalink / raw)
  To: buildroot; +Cc: Stephan Hoffmann, Fabrice Fontaine

gtest unconditionally uses is_trivially_copy_constructible since
version 1.11.0 and
https://github.com/google/googletest/commit/c13c27a513ecd1cbf5700a45fe590e85e8ae6770

So add a dependency on host gcc >= 4.9 for gmock to avoid the following
build failure since commit 9dfbbbb4105c47602da048c9bb9499fb8862e768:

In file included from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/internal/gtest-death-test-internal.h:39:0,
                 from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-death-test.h:41,
                 from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest.h:64,
                 from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/src/gtest-all.cc:38:
/usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-matchers.h: In static member function 'static constexpr bool testing::internal::MatcherBase<T>::IsInlined()':
/usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-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/9d19a47deb80824eaa718d80f14b0afd5f9eb054

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/gtest/Config.in | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/package/gtest/Config.in b/package/gtest/Config.in
index d8bcf6343f..35fc9fea7b 100644
--- a/package/gtest/Config.in
+++ b/package/gtest/Config.in
@@ -26,6 +26,7 @@ if BR2_PACKAGE_GTEST
 
 config BR2_PACKAGE_GTEST_GMOCK
 	bool "gmock"
+	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-gtest
 	help
 	  Inspired by jMock, EasyMock, and Hamcrest, and designed with
 	  C++'s specifics in mind, Google C++ Mocking Framework (or
@@ -47,6 +48,9 @@ config BR2_PACKAGE_GTEST_GMOCK
 	  libraries required to link/run them. The host package installs
 	  gmock_gen, a Python script used to generate code mocks.
 
+comment "gmock needs host gcc >= 4.9"
+	depends on !BR2_HOST_GCC_AT_LEAST_4_9
+
 endif # BR2_PACKAGE_GTEST
 
 comment "gtest needs a toolchain w/ C++, wchar, threads, gcc >= 4.9"
-- 
2.35.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks
  2022-05-30 20:47 [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Fabrice Fontaine
@ 2022-05-30 20:47 ` Fabrice Fontaine
  2022-06-07 15:45   ` Peter Korsgaard
  2022-06-04 16:29 ` [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Yann E. MORIN
  2022-06-07 15:45 ` Peter Korsgaard
  2 siblings, 1 reply; 5+ messages in thread
From: Fabrice Fontaine @ 2022-05-30 20:47 UTC (permalink / raw)
  To: buildroot; +Cc: Stephan Hoffmann, Fabrice Fontaine

Since commit 6a9c6311f8fd4464b5555773589f587338f694a0, two
BR2_PACKAGE_GTEST_GMOCK blocks are used instead of one which is a little
bit unusual

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/gtest/gtest.mk | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/package/gtest/gtest.mk b/package/gtest/gtest.mk
index e7ce89a3f4..8ec5e9c535 100644
--- a/package/gtest/gtest.mk
+++ b/package/gtest/gtest.mk
@@ -13,10 +13,6 @@ GTEST_LICENSE_FILES = LICENSE
 GTEST_CPE_ID_VENDOR = google
 GTEST_CPE_ID_PRODUCT = google_test
 
-ifeq ($(BR2_PACKAGE_GTEST_GMOCK),y)
-GTEST_DEPENDENCIES += host-gtest
-endif
-
 HOST_GTEST_LICENSE = Apache-2.0
 HOST_GTEST_LICENSE_FILES = googlemock/scripts/generator/LICENSE
 HOST_GTEST_DEPENDENCIES = host-python3
@@ -38,6 +34,7 @@ GTEST_CONF_OPTS += -DCMAKE_POSITION_INDEPENDENT_CODE=ON
 endif
 
 ifeq ($(BR2_PACKAGE_GTEST_GMOCK),y)
+GTEST_DEPENDENCIES += host-gtest
 GTEST_CONF_OPTS += -DBUILD_GMOCK=ON
 else
 GTEST_CONF_OPTS += -DBUILD_GMOCK=OFF
-- 
2.35.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9
  2022-05-30 20:47 [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Fabrice Fontaine
  2022-05-30 20:47 ` [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks Fabrice Fontaine
@ 2022-06-04 16:29 ` Yann E. MORIN
  2022-06-07 15:45 ` Peter Korsgaard
  2 siblings, 0 replies; 5+ messages in thread
From: Yann E. MORIN @ 2022-06-04 16:29 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Stephan Hoffmann, buildroot

Fabrice, All,

On 2022-05-30 22:47 +0200, Fabrice Fontaine spake thusly:
> gtest unconditionally uses is_trivially_copy_constructible since
> version 1.11.0 and
> https://github.com/google/googletest/commit/c13c27a513ecd1cbf5700a45fe590e85e8ae6770
> 
> So add a dependency on host gcc >= 4.9 for gmock to avoid the following
> build failure since commit 9dfbbbb4105c47602da048c9bb9499fb8862e768:
> 
> In file included from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/internal/gtest-death-test-internal.h:39:0,
>                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-death-test.h:41,
>                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest.h:64,
>                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/src/gtest-all.cc:38:
> /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-matchers.h: In static member function 'static constexpr bool testing::internal::MatcherBase<T>::IsInlined()':
> /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-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/9d19a47deb80824eaa718d80f14b0afd5f9eb054
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Both patches applied to master, thanks.

Regards,
Yann E. MORIN.

> ---
>  package/gtest/Config.in | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/package/gtest/Config.in b/package/gtest/Config.in
> index d8bcf6343f..35fc9fea7b 100644
> --- a/package/gtest/Config.in
> +++ b/package/gtest/Config.in
> @@ -26,6 +26,7 @@ if BR2_PACKAGE_GTEST
>  
>  config BR2_PACKAGE_GTEST_GMOCK
>  	bool "gmock"
> +	depends on BR2_HOST_GCC_AT_LEAST_4_9 # host-gtest
>  	help
>  	  Inspired by jMock, EasyMock, and Hamcrest, and designed with
>  	  C++'s specifics in mind, Google C++ Mocking Framework (or
> @@ -47,6 +48,9 @@ config BR2_PACKAGE_GTEST_GMOCK
>  	  libraries required to link/run them. The host package installs
>  	  gmock_gen, a Python script used to generate code mocks.
>  
> +comment "gmock needs host gcc >= 4.9"
> +	depends on !BR2_HOST_GCC_AT_LEAST_4_9
> +
>  endif # BR2_PACKAGE_GTEST
>  
>  comment "gtest needs a toolchain w/ C++, wchar, threads, gcc >= 4.9"
> -- 
> 2.35.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9
  2022-05-30 20:47 [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Fabrice Fontaine
  2022-05-30 20:47 ` [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks Fabrice Fontaine
  2022-06-04 16:29 ` [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Yann E. MORIN
@ 2022-06-07 15:45 ` Peter Korsgaard
  2 siblings, 0 replies; 5+ messages in thread
From: Peter Korsgaard @ 2022-06-07 15:45 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Stephan Hoffmann, buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > gtest unconditionally uses is_trivially_copy_constructible since
 > version 1.11.0 and
 > https://github.com/google/googletest/commit/c13c27a513ecd1cbf5700a45fe590e85e8ae6770

 > So add a dependency on host gcc >= 4.9 for gmock to avoid the following
 > build failure since commit 9dfbbbb4105c47602da048c9bb9499fb8862e768:

 > In file included from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/internal/gtest-death-test-internal.h:39:0,
 >                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-death-test.h:41,
 >                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest.h:64,
 >                  from /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/src/gtest-all.cc:38:
 > /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-gtest-1.11.0/googletest/include/gtest/gtest-matchers.h: In static member function 'static constexpr bool testing::internal::MatcherBase<T>::IsInlined()':
 > /usr/lfs/hdd_v1/rc-buildroot-test/scripts/instance-1/output-1/build/host-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/9d19a47deb80824eaa718d80f14b0afd5f9eb054

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2022.02.x, thanks.

-- 
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks
  2022-05-30 20:47 ` [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks Fabrice Fontaine
@ 2022-06-07 15:45   ` Peter Korsgaard
  0 siblings, 0 replies; 5+ messages in thread
From: Peter Korsgaard @ 2022-06-07 15:45 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Stephan Hoffmann, buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > Since commit 6a9c6311f8fd4464b5555773589f587338f694a0, two
 > BR2_PACKAGE_GTEST_GMOCK blocks are used instead of one which is a little
 > bit unusual

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2022.02.x, thanks.

-- 
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-06-07 15:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-30 20:47 [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Fabrice Fontaine
2022-05-30 20:47 ` [Buildroot] [PATCH 2/2] package/gtest: merge BR2_PACKAGE_GTEST_GMOCK blocks Fabrice Fontaine
2022-06-07 15:45   ` Peter Korsgaard
2022-06-04 16:29 ` [Buildroot] [PATCH 1/2] package/gtest: gmock needs host gcc >= 4.9 Yann E. MORIN
2022-06-07 15:45 ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.