diff mbox series

[v2,20/28] systemtap: Pin to build with GCC

Message ID 20250520-clang-toolchain-v2-20-db97c2eb3756@gmail.com
State Accepted, archived
Commit 887c52532f9555f363b06692a777a66fc8137513
Headers show
Series clang: Add clang C/C++ toolchain | expand

Commit Message

Khem Raj May 21, 2025, 6:19 a.m. UTC
clang find a lot of warning

| In file included from ../git/tapset-procfs.cxx:11:
| ../git/session.h:169:47: error: 'used' attribute ignored on a non-definition declaration [-Werror,-Wignored-attributes]
|   169 |   static const char* morehelp __attribute__ ((used));
|       |                                               ^

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/recipes-kernel/systemtap/systemtap_git.bb | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Ross Burton May 22, 2025, 10:01 a.m. UTC | #1
On 21 May 2025, at 07:19, Khem Raj via lists.openembedded.org <raj.khem=gmail.com@lists.openembedded.org> wrote:
> 
> clang find a lot of warning
> 
> | In file included from ../git/tapset-procfs.cxx:11:
> | ../git/session.h:169:47: error: 'used' attribute ignored on a non-definition declaration [-Werror,-Wignored-attributes]
> |   169 |   static const char* morehelp __attribute__ ((used));
> |       |                                               ^
> 
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ---
> meta/recipes-kernel/systemtap/systemtap_git.bb | 4 ++++
> 1 file changed, 4 insertions(+)
> 
> diff --git a/meta/recipes-kernel/systemtap/systemtap_git.bb b/meta/recipes-kernel/systemtap/systemtap_git.bb
> index 21d50ffb04977bdd9666fbabb5e27289aff01370..254bac4d6f9c8637c575b4b7896322bd42e96841 100644
> --- a/meta/recipes-kernel/systemtap/systemtap_git.bb
> +++ b/meta/recipes-kernel/systemtap/systemtap_git.bb
> @@ -99,3 +99,7 @@ do_install:append () {
> }
> 
> BBCLASSEXTEND = "nativesdk"
> +
> +# Emits lot of warning which are treated as errors
> +# They must be looked into before disabling
> +TOOLCHAIN = “gcc"

Upstream configure.ac has a —disable-error which is probably the right thing to do:

https://sourceware.org/git/?p=systemtap.git;a=blob;f=configure.ac;h=6fc9527650413569300aa41cb154757ecc06be97;hb=HEAD#l126

Ross
Khem Raj May 22, 2025, 4:19 p.m. UTC | #2
On Thu, May 22, 2025 at 3:02 AM Ross Burton <Ross.Burton@arm.com> wrote:
>
> On 21 May 2025, at 07:19, Khem Raj via lists.openembedded.org <raj.khem=gmail.com@lists.openembedded.org> wrote:
> >
> > clang find a lot of warning
> >
> > | In file included from ../git/tapset-procfs.cxx:11:
> > | ../git/session.h:169:47: error: 'used' attribute ignored on a non-definition declaration [-Werror,-Wignored-attributes]
> > |   169 |   static const char* morehelp __attribute__ ((used));
> > |       |                                               ^
> >
> > Signed-off-by: Khem Raj <raj.khem@gmail.com>
> > ---
> > meta/recipes-kernel/systemtap/systemtap_git.bb | 4 ++++
> > 1 file changed, 4 insertions(+)
> >
> > diff --git a/meta/recipes-kernel/systemtap/systemtap_git.bb b/meta/recipes-kernel/systemtap/systemtap_git.bb
> > index 21d50ffb04977bdd9666fbabb5e27289aff01370..254bac4d6f9c8637c575b4b7896322bd42e96841 100644
> > --- a/meta/recipes-kernel/systemtap/systemtap_git.bb
> > +++ b/meta/recipes-kernel/systemtap/systemtap_git.bb
> > @@ -99,3 +99,7 @@ do_install:append () {
> > }
> >
> > BBCLASSEXTEND = "nativesdk"
> > +
> > +# Emits lot of warning which are treated as errors
> > +# They must be looked into before disabling
> > +TOOLCHAIN = “gcc"
>
> Upstream configure.ac has a —disable-error which is probably the right thing to do:
>
> https://sourceware.org/git/?p=systemtap.git;a=blob;f=configure.ac;h=6fc9527650413569300aa41cb154757ecc06be97;hb=HEAD#l126
>

yeah it is not sufficient though, there still are warnings reported as
errors - https://termbin.com/o1qn

> Ross
diff mbox series

Patch

diff --git a/meta/recipes-kernel/systemtap/systemtap_git.bb b/meta/recipes-kernel/systemtap/systemtap_git.bb
index 21d50ffb04977bdd9666fbabb5e27289aff01370..254bac4d6f9c8637c575b4b7896322bd42e96841 100644
--- a/meta/recipes-kernel/systemtap/systemtap_git.bb
+++ b/meta/recipes-kernel/systemtap/systemtap_git.bb
@@ -99,3 +99,7 @@  do_install:append () {
 }
 
 BBCLASSEXTEND = "nativesdk"
+
+# Emits lot of warning which are treated as errors
+# They must be looked into before disabling
+TOOLCHAIN = "gcc"