[dpdk-dev] [PATCH 01/17] build: add initial infrastructure for meson & ninja builds

Bruce Richardson bruce.richardson at intel.com
Mon Sep 4 15:51:01 CEST 2017


On Mon, Sep 04, 2017 at 02:36:42PM +0100, Van Haaren, Harry wrote:
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Bruce Richardson
> > Sent: Friday, September 1, 2017 11:04 AM
> > To: dev at dpdk.org
> > Cc: Richardson, Bruce <bruce.richardson at intel.com>
> > Subject: [dpdk-dev] [PATCH 01/17] build: add initial infrastructure for meson & ninja builds
> > 
> > To build with meson and ninja, we need some initial infrastructure in
> > place. The build files for meson always need to be called "meson.build",
> > and options get placed in meson_options.txt
> > 
> > This commit adds a top-level meson.build file, which sets up the global
> > variables for tracking drivers, libraries, etc., and then includes other
> > build files, before finishing by writing the global build configuration
> > header file and a DPDK pkgconfig file at the end, using some of those same
> > globals.
> > 
> > From the top level build file, the only include file thus far is for the
> > config folder, which does some other setup of global configuration
> > parameters, including pulling in architecture specific parameters from an
> > architectural subdirectory. A number of configuration build options are
> > provided for the project to tune a number of global variables which will be
> > used later e.g. max numa nodes, max cores, etc. These settings all make
> > their way to the global build config header "rte_build_config.h". There is
> > also a file "rte_config.h", which includes "rte_build_config.h", and this
> > file is meant to hold other build-time values which are present in our
> > current static build configuration but are not normally meant for
> > user-configuration. Ideally, over time, the values placed here should be
> > moved to the individual libraries or drivers which want those values.
> > 
> > Signed-off-by: Bruce Richardson <bruce.richardson at intel.com>
> 
> Comments inline below;
> 
> <snip>
> 
> > diff --git a/config/meson.build b/config/meson.build
> <snip>
> > +# disable any unwanted warnings
> > +unwanted_warnings = [
> > +	'-Wno-address-of-packed-member',
> > +	'-Wno-format-truncation'
> > +]
> > +foreach arg: unwanted_warnings
> > +	if cc.has_argument(arg)
> > +		add_project_arguments(arg, language: 'c')
> > +	endif
> > +endforeach
> 
> I can't fault the code here, or Meson, just noting that the disabling of these warnings causes prints on GCC 4.8.5 and GCC 5.4.0, GCC 7 only prints on -Wno-address-of-packed-member. Clang handles it correctly - and no out-of-the-ordinary prints occur. No code changes required here.
>

Strange. Just tested with gcc 4.8.5 and gcc 5.4, and everything worked as
expected, no errors or warnings.

> 
> > diff --git a/config/rte_config.h b/config/rte_config.h
> > new file mode 100644
> > index 000000000..79b0db90f
> > --- /dev/null
> > +++ b/config/rte_config.h
> > @@ -0,0 +1,50 @@
> > +/*
> > + *   BSD LICENSE
> > + *
> > + *   Copyright(c) 2016 Intel Corporation. All rights reserved.
> > + *   All rights reserved.
> 
> 2017 for license year

Good catch, will fix in V2.

> 
> <snip>
> 
> Reviewed-by: Harry van Haaren <harry.van.haaren at intel.com>


More information about the dev mailing list