Subject: Re: linux-next: build failure after merge of the perf tree

From: Arnaldo Carvalho de Melo <[email-masked]>
Date: Tue, 2 Apr 2024 17:17:47 -0300

On Tue, Apr 02, 2024 at 09:41:16AM +1100, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the perf tree, today's linux-next build (native i.e. ppc64le
> perf) failed like this:
> 
> make[3]: *** No rule to make target '/home/sfr/next/next/tools/include/uapi/linux/stat.h', needed by '/home/sfr/next/perf/libbpf/staticobjs/libbpf.o'.  Stop.
> 
> Maybe caused by commit
> 
>   f122b3d6d179 ("perf beauty: Introduce scrape script for the 'statx' syscall 'mask' argument")
> 
> or
> 
>   a672af9139a8 ("tools headers: Remove almost unused copy of uapi/stat.h, add few conditional defines")
> 
> or a combination of them?

Right, these are headers that were used to extract string tables but
were added to a directory that was also used to build tools, sometimes
because headers contained new defines that wouldn't be available in
older distros.

We're trying to move things that are needed just for creating string
tables to a separate directory, as done in the second cset you mentioned
above, how to do it in a way that is noticed by the dependency files
cached by the tools build processes is what is needed here.

I planned to investigate and fix this, but this was preventing
development work to proceed as 6.9-rc was released, so I ended up moving
these to perf-tools-next, I'll try again to investigate the deps issue
to make this (and further work in this area) to avoid requiring these
'make clean' steps.

> This is an incremental build but doing 'make -C tools/perf clean' and then
> rebuilding works, so maybe there is a dependency missing?

Thanks for reporting.

- Arnaldo