bpf.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make
@ 2020-09-17 11:58 Tony Ambardar
  2020-09-17 14:56 ` Quentin Monnet
  2020-09-18 23:11 ` Daniel Borkmann
  0 siblings, 2 replies; 5+ messages in thread
From: Tony Ambardar @ 2020-09-17 11:58 UTC (permalink / raw)
  To: Alexei Starovoitov, Daniel Borkmann; +Cc: Tony Ambardar, netdev, bpf

This change facilitates out-of-tree builds, packaging, and versioning for
test and debug purposes. Defining BPFTOOL_VERSION allows self-contained
builds within the tools tree, since it avoids use of the 'kernelversion'
target in the top-level makefile, which would otherwise pull in several
other includes from outside the tools tree.

Signed-off-by: Tony Ambardar <Tony.Ambardar@gmail.com>
---
 tools/bpf/bpftool/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/bpf/bpftool/Makefile b/tools/bpf/bpftool/Makefile
index 8462690a039b..4828913703b6 100644
--- a/tools/bpf/bpftool/Makefile
+++ b/tools/bpf/bpftool/Makefile
@@ -25,7 +25,7 @@ endif
 
 LIBBPF = $(LIBBPF_PATH)libbpf.a
 
-BPFTOOL_VERSION := $(shell make -rR --no-print-directory -sC ../../.. kernelversion)
+BPFTOOL_VERSION ?= $(shell make -rR --no-print-directory -sC ../../.. kernelversion)
 
 $(LIBBPF): FORCE
 	$(if $(LIBBPF_OUTPUT),@mkdir -p $(LIBBPF_OUTPUT))
-- 
2.25.1


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

* Re: [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make
  2020-09-17 11:58 [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make Tony Ambardar
@ 2020-09-17 14:56 ` Quentin Monnet
  2020-09-17 23:27   ` Song Liu
  2020-09-18 23:11 ` Daniel Borkmann
  1 sibling, 1 reply; 5+ messages in thread
From: Quentin Monnet @ 2020-09-17 14:56 UTC (permalink / raw)
  To: Tony Ambardar, Alexei Starovoitov, Daniel Borkmann; +Cc: netdev, bpf

On 17/09/2020 12:58, Tony Ambardar wrote:
> This change facilitates out-of-tree builds, packaging, and versioning for
> test and debug purposes. Defining BPFTOOL_VERSION allows self-contained
> builds within the tools tree, since it avoids use of the 'kernelversion'
> target in the top-level makefile, which would otherwise pull in several
> other includes from outside the tools tree.
> 
> Signed-off-by: Tony Ambardar <Tony.Ambardar@gmail.com>

Acked-by: Quentin Monnet <quentin@isovalent.com>

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

* Re: [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make
  2020-09-17 14:56 ` Quentin Monnet
@ 2020-09-17 23:27   ` Song Liu
  2020-09-18  1:08     ` Tony Ambardar
  0 siblings, 1 reply; 5+ messages in thread
From: Song Liu @ 2020-09-17 23:27 UTC (permalink / raw)
  To: Quentin Monnet
  Cc: Tony Ambardar, Alexei Starovoitov, Daniel Borkmann, Networking, bpf

On Thu, Sep 17, 2020 at 7:58 AM Quentin Monnet <quentin@isovalent.com> wrote:
>
> On 17/09/2020 12:58, Tony Ambardar wrote:
> > This change facilitates out-of-tree builds, packaging, and versioning for
> > test and debug purposes. Defining BPFTOOL_VERSION allows self-contained
> > builds within the tools tree, since it avoids use of the 'kernelversion'
> > target in the top-level makefile, which would otherwise pull in several
> > other includes from outside the tools tree.
> >
> > Signed-off-by: Tony Ambardar <Tony.Ambardar@gmail.com>
>
> Acked-by: Quentin Monnet <quentin@isovalent.com>

Acked-by: Song Liu <songliubraving@fb.com>

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

* Re: [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make
  2020-09-17 23:27   ` Song Liu
@ 2020-09-18  1:08     ` Tony Ambardar
  0 siblings, 0 replies; 5+ messages in thread
From: Tony Ambardar @ 2020-09-18  1:08 UTC (permalink / raw)
  To: Song Liu
  Cc: Quentin Monnet, Alexei Starovoitov, Daniel Borkmann, Networking, bpf

On Thu, 17 Sep 2020 at 16:27, Song Liu <song@kernel.org> wrote:
>
> On Thu, Sep 17, 2020 at 7:58 AM Quentin Monnet <quentin@isovalent.com> wrote:
> >
> > On 17/09/2020 12:58, Tony Ambardar wrote:
> > > This change facilitates out-of-tree builds, packaging, and versioning for
> > > test and debug purposes. Defining BPFTOOL_VERSION allows self-contained
> > > builds within the tools tree, since it avoids use of the 'kernelversion'
> > > target in the top-level makefile, which would otherwise pull in several
> > > other includes from outside the tools tree.
> > >
> > > Signed-off-by: Tony Ambardar <Tony.Ambardar@gmail.com>
> >
> > Acked-by: Quentin Monnet <quentin@isovalent.com>
>
> Acked-by: Song Liu <songliubraving@fb.com>

I should clarify for those performing stand-alone builds that a few
items are still required from outside the tools/ tree:
kernel/bpf/disasm.[ch] and scripts/bpf_helpers_doc.py. Not sure that's
worth updating the commit description however.

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

* Re: [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make
  2020-09-17 11:58 [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make Tony Ambardar
  2020-09-17 14:56 ` Quentin Monnet
@ 2020-09-18 23:11 ` Daniel Borkmann
  1 sibling, 0 replies; 5+ messages in thread
From: Daniel Borkmann @ 2020-09-18 23:11 UTC (permalink / raw)
  To: Tony Ambardar, Alexei Starovoitov; +Cc: netdev, bpf

On 9/17/20 1:58 PM, Tony Ambardar wrote:
> This change facilitates out-of-tree builds, packaging, and versioning for
> test and debug purposes. Defining BPFTOOL_VERSION allows self-contained
> builds within the tools tree, since it avoids use of the 'kernelversion'
> target in the top-level makefile, which would otherwise pull in several
> other includes from outside the tools tree.
> 
> Signed-off-by: Tony Ambardar <Tony.Ambardar@gmail.com>

Applied, thanks!

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

end of thread, other threads:[~2020-09-18 23:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-17 11:58 [PATCH bpf v1] tools/bpftool: support passing BPFTOOL_VERSION to make Tony Ambardar
2020-09-17 14:56 ` Quentin Monnet
2020-09-17 23:27   ` Song Liu
2020-09-18  1:08     ` Tony Ambardar
2020-09-18 23:11 ` Daniel Borkmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).