[dpdk-stable] [PATCH] build: provide suitable error for "both" libraries option

Andrew Boyer aboyer at pensando.io
Mon Jan 11 17:19:26 CET 2021



> On Jan 11, 2021, at 8:55 AM, Bruce Richardson <bruce.richardson at intel.com> wrote:
> 
> Rather than having the DPDK configuration error out when linking apps
> and examples when "both" is select for "default_library" option, we can
> detect that setting earlier in the build config and provide a suitable
> error message to the user.
> 
> CC: stable at dpdk.org
> 
> Signed-off-by: Bruce Richardson <bruce.richardson at intel.com>
> ---
> config/meson.build | 9 +++++++++
> 1 file changed, 9 insertions(+)
> 
> diff --git a/config/meson.build b/config/meson.build
> index 3ddcc3539..05e9cede5 100644
> --- a/config/meson.build
> +++ b/config/meson.build
> @@ -308,3 +308,12 @@ if get_option('b_lto')
> 		add_project_link_arguments('-Wno-lto-type-mismatch', language: 'c')
> 	endif
> endif
> +
> +if get_option('default_library') == 'both'
> +	error( '''
> +    Unsupported value "both" for "default_library" option.
> +
> +    NOTE: DPDK always builds both shared and static libraries.  Please set
> +    "default_library" to either "static" or "shared" to select default linkage
> +    for apps and any examples''')

Should there be a period after ‘examples’?

> +endif
> --
> 2.27.0
> 


Reviewed-by: Andrew Boyer <aboyer at pensando.io>



More information about the stable mailing list