Re: [PATCH bpf-next v1 1/2] bpf: changes_pkt_data: correct the 'main' error

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

 



On Fri, Feb 7, 2025 at 2:04 PM Martin KaFai Lau <martin.lau@xxxxxxxxx> wrote:
>
> On 2/3/25 6:39 PM, Jason Xing wrote:
> > When compiling the selftests, the following error is printed out:
> > selftests/bpf/prog_tests/changes_pkt_data.c: In function ‘test_aux’:
> > selftests/bpf/prog_tests/changes_pkt_data.c:22:27: error: ‘main’ is usually a function [-Werror=main]
> >    struct changes_pkt_data *main = NULL;
>
> The bpf CI has been testing this piece with different compilers. I also don't
> see it in my environment. How to reproduce it and which compiler?

The gcc version is "gcc version 8.5.0" which is an old one. Yep, there
are some cases sometimes where bpf CI doesn't report because the
compilation relies on the system environment? Sorry that I have no
clue about this happening. One thing I know is that if using some old
distros and cloud services, it's not hard to see this.

In this series, rename it to avoid error messages which could stop the
local compilation.

Thanks,
Jason





[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux