From: Eduard Zingerman <eddyz87@gmail.com>
To: Mykola Lysenko <nickolay.lysenko@gmail.com>, bpf@vger.kernel.org
Cc: ast@kernel.org, daniel@iogearbox.net, andrii@kernel.org,
martin.lau@linux.dev, song@kernel.org, yonghong.song@linux.dev,
jolsa@kernel.org, memxor@gmail.com
Subject: Re: [RFC PATCH bpf-next v5 7/8] selftests/bpf: move shared build definitions into Makefile.buildvars
Date: Wed, 05 Aug 2026 16:34:30 -0700 [thread overview]
Message-ID: <9a2504bb38bd0760448fe483829c14e697a9b650.camel@gmail.com> (raw)
In-Reply-To: <20260804170156.1709916-8-nickolay.lysenko@gmail.com>
On Tue, 2026-08-04 at 10:01 -0700, Mykola Lysenko wrote:
...
Thank you for taking time to reshuffle the diff, such that the
Makefile.buildvars preserves the original relative order.
Much easier to review.
...
> --- a/tools/testing/selftests/bpf/Makefile
> +++ b/tools/testing/selftests/bpf/Makefile
> @@ -3,60 +3,15 @@ include ../../../build/Build.include
...
> -GENHDR := $(GENDIR)/autoconf.h
> PKG_CONFIG ?= $(CROSS_COMPILE)pkg-config
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
It seems this can be removed as well, all uses are after
Makefile.buildvars is included. Or is it needed for one of the other
includes?
...
> @@ -220,21 +151,8 @@ ifeq ($(feature-llvm),1)
...
> -HOST_BPFOBJ := $(HOST_BUILD_DIR)/libbpf/libbpf.a
> -RESOLVE_BTFIDS := $(HOST_BUILD_DIR)/resolve_btfids/resolve_btfids
> +include Makefile.buildvars
It appears that this include can be moved up, to the lib.mk include.
In this case the duplicate definitions for `srctree` and `PKG_CONFIG`
can be removed (and both can reside in Makefile.buildvars).
Wdyt?
...
> --- /dev/null
> +++ b/tools/testing/selftests/bpf/Makefile.buildvars
...
> +PKG_CONFIG ?= $(CROSS_COMPILE)pkg-config
...
> +ifeq ($(srctree),)
> +srctree := $(patsubst %/,%,$(dir $(CURDIR)))
> +srctree := $(patsubst %/,%,$(dir $(srctree)))
> +srctree := $(patsubst %/,%,$(dir $(srctree)))
> +srctree := $(patsubst %/,%,$(dir $(srctree)))
> +endif
In case if shuffling includes around does not work, can we export
`srctree` in the main makefile and not copy it here?
...
next prev parent reply other threads:[~2026-08-05 23:34 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-04 17:01 [RFC PATCH bpf-next v5 0/8] selftests/bpf: restructure the Makefile as a layered build Mykola Lysenko
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 1/8] selftests/bpf: keep headers off the generic link command line Mykola Lysenko
2026-08-05 21:21 ` Eduard Zingerman
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 2/8] selftests/bpf: drop stale and no-op lines Mykola Lysenko
2026-08-05 21:28 ` Eduard Zingerman
2026-08-06 4:43 ` Mykola Lysenko
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 3/8] selftests/bpf: factor the permissive-mode skip suffix into a helper Mykola Lysenko
2026-08-04 17:21 ` sashiko-bot
2026-08-05 0:13 ` Mykola Lysenko
2026-08-05 21:33 ` Eduard Zingerman
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 4/8] selftests/bpf: generate the signing key and certificate once Mykola Lysenko
2026-08-05 22:03 ` Eduard Zingerman
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 5/8] selftests/bpf: generate verifier/tests.h in a regular recipe Mykola Lysenko
2026-08-05 22:11 ` Eduard Zingerman
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 6/8] selftests/bpf: extract BPF skeleton generation into a helper script Mykola Lysenko
2026-08-04 17:59 ` sashiko-bot
2026-08-05 1:40 ` Mykola Lysenko
2026-08-05 22:39 ` Eduard Zingerman
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 7/8] selftests/bpf: move shared build definitions into Makefile.buildvars Mykola Lysenko
2026-08-05 23:34 ` Eduard Zingerman [this message]
2026-08-06 4:51 ` Mykola Lysenko
2026-08-04 17:01 ` [RFC PATCH bpf-next v5 8/8] selftests/bpf: build each test runner instance in its own sub-make Mykola Lysenko
2026-08-06 8:02 ` Eduard Zingerman
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=9a2504bb38bd0760448fe483829c14e697a9b650.camel@gmail.com \
--to=eddyz87@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=jolsa@kernel.org \
--cc=martin.lau@linux.dev \
--cc=memxor@gmail.com \
--cc=nickolay.lysenko@gmail.com \
--cc=song@kernel.org \
--cc=yonghong.song@linux.dev \
/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