* [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy
@ 2022-03-24 22:32 Fabrice Fontaine
2022-03-25 5:38 ` Maxim Kochetkov via buildroot
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2022-03-24 22:32 UTC (permalink / raw)
To: buildroot; +Cc: Maxim Kochetkov, Fabrice Fontaine
Fix the following build failure if clang-tidy is found on host (and
protobuf is built before protozero) which is raised since tests are
disabled in commit be4869f393561aa5c297b631efc62dfd5e1c3f3f:
CMake Error at CMakeLists.txt:77 (add_dependencies):
The dependency target "writer_tests" of target "clang-tidy" does not exist.
Fixes:
- http://autobuild.buildroot.org/results/c3ae3b5caf79eb30c8a1786f58abea4f2b41a26e
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
...xt-protobuf-is-only-needed-for-tests.patch | 35 +++++++++++++++++++
1 file changed, 35 insertions(+)
create mode 100644 package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
diff --git a/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch b/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
new file mode 100644
index 0000000000..3033e24aa2
--- /dev/null
+++ b/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
@@ -0,0 +1,35 @@
+From 1c16d3ffccd9e415c6ea3681f23231cd5184043c Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Wed, 16 Feb 2022 00:11:38 +0100
+Subject: [PATCH] CMakeLists.txt: protobuf is only needed for tests
+
+Don't check for protobuf if tests are disabled. As a side effect, this
+will avoid a build failure if clang-tidy and protobuf are found but
+tests are disabled
+
+Fix #109
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Upstream status: https://github.com/mapbox/protozero/pull/110]
+---
+ CMakeLists.txt | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index b975d49..df2ca15 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -52,7 +52,9 @@ endif()
+ #
+ #-----------------------------------------------------------------------------
+
+-find_package(Protobuf)
++if(BUILD_TESTING)
++ find_package(Protobuf)
++endif()
+
+
+ #-----------------------------------------------------------------------------
+--
+2.34.1
+
--
2.35.1
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy
2022-03-24 22:32 [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy Fabrice Fontaine
@ 2022-03-25 5:38 ` Maxim Kochetkov via buildroot
2022-03-27 16:28 ` Arnout Vandecappelle
2022-03-31 11:36 ` Peter Korsgaard
2 siblings, 0 replies; 4+ messages in thread
From: Maxim Kochetkov via buildroot @ 2022-03-25 5:38 UTC (permalink / raw)
To: Fabrice Fontaine, buildroot
On 25.03.2022 01:32, Fabrice Fontaine wrote:
> Fix the following build failure if clang-tidy is found on host (and
> protobuf is built before protozero) which is raised since tests are
> disabled in commit be4869f393561aa5c297b631efc62dfd5e1c3f3f:
>
> CMake Error at CMakeLists.txt:77 (add_dependencies):
> The dependency target "writer_tests" of target "clang-tidy" does not exist.
>
> Fixes:
> - http://autobuild.buildroot.org/results/c3ae3b5caf79eb30c8a1786f58abea4f2b41a26e
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Reviewed-by: Maxim Kochetkov <fido_max@inbox.ru>
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy
2022-03-24 22:32 [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy Fabrice Fontaine
2022-03-25 5:38 ` Maxim Kochetkov via buildroot
@ 2022-03-27 16:28 ` Arnout Vandecappelle
2022-03-31 11:36 ` Peter Korsgaard
2 siblings, 0 replies; 4+ messages in thread
From: Arnout Vandecappelle @ 2022-03-27 16:28 UTC (permalink / raw)
To: Fabrice Fontaine, buildroot; +Cc: Maxim Kochetkov
On 24/03/2022 23:32, Fabrice Fontaine wrote:
> Fix the following build failure if clang-tidy is found on host (and
> protobuf is built before protozero) which is raised since tests are
> disabled in commit be4869f393561aa5c297b631efc62dfd5e1c3f3f:
>
> CMake Error at CMakeLists.txt:77 (add_dependencies):
> The dependency target "writer_tests" of target "clang-tidy" does not exist.
>
> Fixes:
> - http://autobuild.buildroot.org/results/c3ae3b5caf79eb30c8a1786f58abea4f2b41a26e
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Applied to master, thanks.
Regards,
Arnout
> ---
> ...xt-protobuf-is-only-needed-for-tests.patch | 35 +++++++++++++++++++
> 1 file changed, 35 insertions(+)
> create mode 100644 package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
>
> diff --git a/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch b/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
> new file mode 100644
> index 0000000000..3033e24aa2
> --- /dev/null
> +++ b/package/protozero/0001-CMakeLists.txt-protobuf-is-only-needed-for-tests.patch
> @@ -0,0 +1,35 @@
> +From 1c16d3ffccd9e415c6ea3681f23231cd5184043c Mon Sep 17 00:00:00 2001
> +From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +Date: Wed, 16 Feb 2022 00:11:38 +0100
> +Subject: [PATCH] CMakeLists.txt: protobuf is only needed for tests
> +
> +Don't check for protobuf if tests are disabled. As a side effect, this
> +will avoid a build failure if clang-tidy and protobuf are found but
> +tests are disabled
> +
> +Fix #109
> +
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +[Upstream status: https://github.com/mapbox/protozero/pull/110]
> +---
> + CMakeLists.txt | 4 +++-
> + 1 file changed, 3 insertions(+), 1 deletion(-)
> +
> +diff --git a/CMakeLists.txt b/CMakeLists.txt
> +index b975d49..df2ca15 100644
> +--- a/CMakeLists.txt
> ++++ b/CMakeLists.txt
> +@@ -52,7 +52,9 @@ endif()
> + #
> + #-----------------------------------------------------------------------------
> +
> +-find_package(Protobuf)
> ++if(BUILD_TESTING)
> ++ find_package(Protobuf)
> ++endif()
> +
> +
> + #-----------------------------------------------------------------------------
> +--
> +2.34.1
> +
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy
2022-03-24 22:32 [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy Fabrice Fontaine
2022-03-25 5:38 ` Maxim Kochetkov via buildroot
2022-03-27 16:28 ` Arnout Vandecappelle
@ 2022-03-31 11:36 ` Peter Korsgaard
2 siblings, 0 replies; 4+ messages in thread
From: Peter Korsgaard @ 2022-03-31 11:36 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: Maxim Kochetkov, buildroot
>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:
> Fix the following build failure if clang-tidy is found on host (and
> protobuf is built before protozero) which is raised since tests are
> disabled in commit be4869f393561aa5c297b631efc62dfd5e1c3f3f:
> CMake Error at CMakeLists.txt:77 (add_dependencies):
> The dependency target "writer_tests" of target "clang-tidy" does not exist.
> Fixes:
> - http://autobuild.buildroot.org/results/c3ae3b5caf79eb30c8a1786f58abea4f2b41a26e
> 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] 4+ messages in thread
end of thread, other threads:[~2022-03-31 11:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-24 22:32 [Buildroot] [PATCH 1/1] package/protozero: fix build with clang-tidy Fabrice Fontaine
2022-03-25 5:38 ` Maxim Kochetkov via buildroot
2022-03-27 16:28 ` Arnout Vandecappelle
2022-03-31 11:36 ` 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.