Warnings in headers when building libpcap with dpdk and clang
Marat Khalili
marat.khalili at huawei.com
Thu Aug 14 15:28:04 CEST 2025
> -----Original Message-----
> From: Francois <devel.fx.lebail at orange.fr>
> Sent: Thursday 14 August 2025 13:54
> To: dev at dpdk.org
> Subject: Warnings in headers when building libpcap with dpdk and clang
>
> Hello,
>
> I notice many warnings. To reproduce:
>
> On Debian bookworm.
>
> sudo apt install dpdk-dev
>
> git clone https://git.tcpdump.org/libpcap
>
> # build with clang
>
> $ ./autogen.sh
>
> $ ./configure CC=clang-16 --with-dpdk
>
> $ make
>
> Warning lines:
> /usr/include/dpdk/rte_ring_elem_pvt.h:13:36: warning: 'GCC_VERSION' is not defined, evaluates to 0 [-
> Wundef]
> What do you think?
For the first warning there was a commit 3cb34fb0b0 "build: set toolchain macros from predefined macros" dated 2024-01-02 that was fixing similar issue. It is possible that documentation issues were fixed since bookworm-shipped version 22.11 as well. Depending on your goals you may try newer DPDK version, compiling libpcap with gcc and/or fewer warnings or just ignoring these warnings.
More information about the dev
mailing list