Re: [PATCH] bpftool: fix iprofiler build on systems without /usr/include/asm symlink

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tobias Klauser <tklauser@xxxxxxxxxx> writes:

> On 2020-03-11 at 13:49:53 +0100, Toke Høiland-Jørgensen <toke@xxxxxxxxxx> wrote:
>> Tobias Klauser <tklauser@xxxxxxxxxx> writes:
>> 
>> > When compiling bpftool on a system where the /usr/include/asm symlink
>> > doesn't exist (e.g. on an Ubuntu system without gcc-multilib installed),
>> > the build fails with:
>> >
>> >     CLANG    skeleton/profiler.bpf.o
>> >   In file included from skeleton/profiler.bpf.c:4:
>> >   In file included from /usr/include/linux/bpf.h:11:
>> >   /usr/include/linux/types.h:5:10: fatal error: 'asm/types.h' file not found
>> >   #include <asm/types.h>
>> >            ^~~~~~~~~~~~~
>> >   1 error generated.
>> >   make: *** [Makefile:123: skeleton/profiler.bpf.o] Error 1
>> >
>> > To fix this, add /usr/include/$(uname -m)-linux-gnu to the clang search
>> > path so <asm/types.h> can be found.
>> 
>> Isn't the right thing here to just install gcc-multilib?
>
> For a container build we would like to avoid installing gcc-multilib
> which pulls in additional dependencies which are otherwise not needed to
> build bpftool. This patch would allow that.

Ah, right. Well, stating that use case in the commit message would have
been nice :)

I'm personally a little skeptical about having to add this (how many
weird build systems should we support?), but I can also see where you're
coming from. Up to the maintainers, I suppose...

-Toke





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux