public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
From: Roberto Sassu <roberto.sassu@huawei.com>
To: Quentin Monnet <quentin@isovalent.com>
Cc: Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>,
	Martin KaFai Lau <martin.lau@linux.dev>,
	Song Liu <song@kernel.org>,
	John Fastabend <john.fastabend@gmail.com>,
	KP Singh <kpsingh@kernel.org>,
	Stanislav Fomichev <sdf@google.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>,
	"terrelln@fb.com" <terrelln@fb.com>,
	Nathan Chancellor <nathan@kernel.org>,
	Nick Desaulniers <ndesaulniers@google.com>,
	bpf <bpf@vger.kernel.org>,
	linux-perf-use. <linux-perf-users@vger.kernel.org>,
	"llvm@lists.linux.dev" <llvm@lists.linux.dev>,
	open list <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH 2/4] bpftool: Complete libbfd feature detection
Date: Wed, 20 Jul 2022 22:37:31 +0000	[thread overview]
Message-ID: <c5a1ca3d8ffa4998970eacf4f8057b1b@huawei.com> (raw)
In-Reply-To: <CACdoK4LMvLyV2z5quN1BE4VrxGJK-f1YfuHWoQrJaH_eKyHZog@mail.gmail.com>

> From: Quentin Monnet [mailto:quentin@isovalent.com]
> Sent: Wednesday, July 20, 2022 10:08 PM
> On Tue, 19 Jul 2022 at 18:06, Roberto Sassu <roberto.sassu@huawei.com>
> wrote:
> >
> > Commit 6e8ccb4f624a7 ("tools/bpf: properly account for libbfd variations")
> > sets the linking flags depending on which flavor of the libbfd feature was
> > detected.
> >
> > However, the flavors except libbfd cannot be detected, as they are not in
> > the feature list.
> >
> > Complete the list of features to detect by adding libbfd-liberty and
> > libbfd-liberty-z.
> >
> > Fixes: 6e8ccb4f624a7 ("tools/bpf: properly account for libbfd variations")
> > Signed-off-by: Roberto Sassu <roberto.sassu@huawei.com>
> > ---
> >  tools/bpf/bpftool/Makefile | 6 ++++--
> >  1 file changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/tools/bpf/bpftool/Makefile b/tools/bpf/bpftool/Makefile
> > index 6b5b3a99f79d..4b09a5c3b9f1 100644
> > --- a/tools/bpf/bpftool/Makefile
> > +++ b/tools/bpf/bpftool/Makefile
> > @@ -93,8 +93,10 @@ INSTALL ?= install
> >  RM ?= rm -f
> >
> >  FEATURE_USER = .bpftool
> > -FEATURE_TESTS = libbfd disassembler-four-args libcap clang-bpf-co-re
> > -FEATURE_DISPLAY = libbfd disassembler-four-args libcap clang-bpf-co-re
> > +FEATURE_TESTS = libbfd libbfd-liberty libbfd-liberty-z \
> > +               disassembler-four-args libcap clang-bpf-co-re
> > +FEATURE_DISPLAY = libbfd libbfd-liberty libbfd-liberty-z \
> > +                 disassembler-four-args libcap clang-bpf-co-re
> 
> Do you know if there is a way to fold the different feature-libbfd-*
> features into a single one for FEATURE_DISPLAY? Or should the various
> features be all moved under feature-libbfd with multiple attempts,
> like you did for disassembler-four-args in patch 1? My concern is that
> users may think some features could be missing when they compile and
> see that detection fails for some items.

I thought about retrying. Hovewer, bpftool Makefile uses the
different flavors to determine exactly which linking flags to use.
Transparent retrying means that this information is lost.

Also very interesting, Ubuntu uses feature-libbfd for the shared
library, feature-libbfd-liberty-z for the static one. 

Roberto

  reply	other threads:[~2022-07-20 22:37 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-19 17:05 [PATCH 1/4] tools, build: Retry detection of bfd-related features Roberto Sassu
2022-07-19 17:05 ` [PATCH 2/4] bpftool: Complete libbfd feature detection Roberto Sassu
2022-07-20 20:07   ` Quentin Monnet
2022-07-20 22:37     ` Roberto Sassu [this message]
2022-07-19 17:05 ` [PATCH 3/4] perf: Remove FEATURE_CHECK_LDFLAGS-disassembler-four-args Roberto Sassu
2022-07-19 17:05 ` [PATCH 4/4] build: Switch to new openssl API for test-libcrypto Roberto Sassu
2022-08-08 16:14   ` Daniel Borkmann
2022-08-08 18:33     ` Arnaldo Carvalho de Melo
2022-08-09 15:15       ` Arnaldo Carvalho de Melo
2022-08-09 15:21         ` Arnaldo Carvalho de Melo
2022-08-09 15:28           ` Roberto Sassu
2022-08-09 16:01             ` Roberto Sassu
2022-08-09 17:00           ` Andres Freund
2022-08-09 19:04             ` Arnaldo Carvalho de Melo
2022-08-09 19:10               ` Arnaldo Carvalho de Melo
2022-08-09 15:21         ` Quentin Monnet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c5a1ca3d8ffa4998970eacf4f8057b1b@huawei.com \
    --to=roberto.sassu@huawei.com \
    --cc=acme@kernel.org \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=john.fastabend@gmail.com \
    --cc=kpsingh@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=martin.lau@linux.dev \
    --cc=mingo@redhat.com \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=peterz@infradead.org \
    --cc=quentin@isovalent.com \
    --cc=sdf@google.com \
    --cc=song@kernel.org \
    --cc=terrelln@fb.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox