From: Jiri Olsa <jolsa@kernel.org> Date: 2021-02-04 21:19:43
hi,
resolve_btfids tool is used during the kernel build,
so we should clean it on kernel's make clean.
thanks,
jirka
---
Jiri Olsa (4):
tools/resolve_btfids: Build libbpf and libsubcmd in separate directories
tools/resolve_btfids: Check objects before removing
tools/resolve_btfids: Set srctree variable unconditionally
kbuild: Add resolve_btfids clean to root clean target
Makefile | 7 ++++++-
tools/bpf/resolve_btfids/.gitignore | 2 --
tools/bpf/resolve_btfids/Makefile | 38 ++++++++++++++++++++------------------
3 files changed, 26 insertions(+), 21 deletions(-)
From: Jiri Olsa <jolsa@kernel.org> Date: 2021-02-04 21:19:44
Setting up separate build directories for libbpf and libpsubcmd,
so it's separated from other objects and we don't get them mixed
in the future.
It also simplifies cleaning, which is now simple rm -rf.
Also there's no need for FEATURE-DUMP.libbpf and bpf_helper_defs.h
files in .gitignore anymore.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/.gitignore | 2 --
tools/bpf/resolve_btfids/Makefile | 26 +++++++++++---------------
2 files changed, 11 insertions(+), 17 deletions(-)
From: Jiri Olsa <jolsa@kernel.org> Date: 2021-02-04 21:19:44
We want this clean to be called from tree's root Makefile,
which defines same srctree variable and that will screw
the make setup.
We actually do not use srctree being passed from outside,
so we can solve this by setting current srctree value
directly.
Also root Makefile does not define the implicit RM variable,
so adding RM initialization.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/Makefile | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
From: Jiri Olsa <jolsa@kernel.org> Date: 2021-02-04 21:19:45
We want this clean to be called from tree's root clean
and that one is silent if there's nothing to clean.
Adding check for all object to clean and display CLEAN
messages only if there are objects to remove.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/Makefile | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
From: Jiri Olsa <jolsa@kernel.org> Date: 2021-02-04 21:19:48
The resolve_btfids tool is used during the kernel build,
so we should clean it on kernel's make clean.
Invoking the the resolve_btfids clean as part of root
'make clean'.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
Makefile | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
On Feb 4, 2021, at 1:18 PM, Jiri Olsa [off-list ref] wrote:
Setting up separate build directories for libbpf and libpsubcmd,
so it's separated from other objects and we don't get them mixed
in the future.
It also simplifies cleaning, which is now simple rm -rf.
Also there's no need for FEATURE-DUMP.libbpf and bpf_helper_defs.h
files in .gitignore anymore.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
On Feb 4, 2021, at 1:18 PM, Jiri Olsa [off-list ref] wrote:
We want this clean to be called from tree's root Makefile,
which defines same srctree variable and that will screw
the make setup.
We actually do not use srctree being passed from outside,
so we can solve this by setting current srctree value
directly.
Also root Makefile does not define the implicit RM variable,
so adding RM initialization.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
On Feb 4, 2021, at 1:18 PM, Jiri Olsa [off-list ref] wrote:
The resolve_btfids tool is used during the kernel build,
so we should clean it on kernel's make clean.
Invoking the the resolve_btfids clean as part of root
'make clean'.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
On Feb 4, 2021, at 1:18 PM, Jiri Olsa [off-list ref] wrote:
We want this clean to be called from tree's root clean
and that one is silent if there's nothing to clean.
Adding check for all object to clean and display CLEAN
messages only if there are objects to remove.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
On Thu, Feb 4, 2021 at 1:20 PM Jiri Olsa [off-list ref] wrote:
quoted hunk
Setting up separate build directories for libbpf and libpsubcmd,
so it's separated from other objects and we don't get them mixed
in the future.
It also simplifies cleaning, which is now simple rm -rf.
Also there's no need for FEATURE-DUMP.libbpf and bpf_helper_defs.h
files in .gitignore anymore.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/.gitignore | 2 --
tools/bpf/resolve_btfids/Makefile | 26 +++++++++++---------------
2 files changed, 11 insertions(+), 17 deletions(-)
On Thu, Feb 4, 2021 at 1:20 PM Jiri Olsa [off-list ref] wrote:
quoted hunk
We want this clean to be called from tree's root clean
and that one is silent if there's nothing to clean.
Adding check for all object to clean and display CLEAN
messages only if there are objects to remove.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/Makefile | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
On Thu, Feb 4, 2021 at 1:21 PM Jiri Olsa [off-list ref] wrote:
quoted hunk
We want this clean to be called from tree's root Makefile,
which defines same srctree variable and that will screw
the make setup.
We actually do not use srctree being passed from outside,
so we can solve this by setting current srctree value
directly.
Also root Makefile does not define the implicit RM variable,
so adding RM initialization.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/Makefile | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
From: Jiri Olsa <hidden> Date: 2021-02-05 10:39:36
On Thu, Feb 04, 2021 at 04:39:38PM -0800, Andrii Nakryiko wrote:
On Thu, Feb 4, 2021 at 1:20 PM Jiri Olsa [off-list ref] wrote:
quoted
Setting up separate build directories for libbpf and libpsubcmd,
so it's separated from other objects and we don't get them mixed
in the future.
It also simplifies cleaning, which is now simple rm -rf.
Also there's no need for FEATURE-DUMP.libbpf and bpf_helper_defs.h
files in .gitignore anymore.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/.gitignore | 2 --
tools/bpf/resolve_btfids/Makefile | 26 +++++++++++---------------
2 files changed, 11 insertions(+), 17 deletions(-)
From: Jiri Olsa <hidden> Date: 2021-02-05 10:44:35
On Thu, Feb 04, 2021 at 04:42:41PM -0800, Andrii Nakryiko wrote:
On Thu, Feb 4, 2021 at 1:20 PM Jiri Olsa [off-list ref] wrote:
quoted
We want this clean to be called from tree's root clean
and that one is silent if there's nothing to clean.
Adding check for all object to clean and display CLEAN
messages only if there are objects to remove.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/bpf/resolve_btfids/Makefile | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)