[dpdk-dev] [PATCH] mk: disable warning with gcc 9 on Fedora 30
thomas at monjalon.net
Thu May 2 17:56:48 CEST 2019
02/05/2019 17:00, David Marchand:
> On Thu, May 2, 2019 at 11:33 AM Reshma Pattan <reshma.pattan at intel.com>
> > gcc 9 on Fedora 30 gives an error
> > "taking address of packed member may result in an
> > unaligned pointer value" warnings.
> > For clang builds this warning is already disabled,
> > so disable "-Waddress-of-packed-member" for gcc builds
> > also.
> > Snippet of build error:
> > ...lib/librte_eal/linux/eal/eal_memalloc.c: In function ‘alloc_seg_walk’:
> > ...lib/librte_eal/linux/eal/eal_memalloc.c:768:12: error: taking address
> > of packed member of ‘struct rte_mem_config’ may result in an unaligned
> > pointer value [-Werror=address-of-packed-member]
> > 768 | cur_msl = &mcfg->memsegs[msl_idx];
> > | ^~~~~~~~~~~~~~~~~~~~~~~
> > Signed-off-by: Reshma Pattan <reshma.pattan at intel.com>
> Tested on rhel-7 and fedora-30.
> Tested-by: David Marchand <david.marchand at redhat.com>
More information about the dev