[Mesa-dev] [PATCH] freedreno: add -Wno-packed-bitfield-compat for meson build

Eric Engestrom eric.engestrom at imgtec.com
Mon Dec 4 14:06:08 UTC 2017


On Monday, 2017-12-04 08:44:59 -0500, Rob Clark wrote:
> Otherwise huge amount of spam from instr-a2xx.h.. gcc has no way to know
> that freedreno was never built with such an old gcc version to care
> about the bugs in old gcc ;-)
> 
> Patch is really Eric Engestrom's, he showed me how to do this in meson.
> 
> Cc: Eric Engestrom <eric.engestrom at imgtec.com>
> Signed-off-by: Rob Clark <robdclark at gmail.com>

Not sure it makes much sense to r-b my own patch, but... ^^
Reviewed-by: Eric Engestrom <eric.engestrom at imgtec.com>

> ---
>  src/gallium/drivers/freedreno/meson.build | 14 ++++++++++++--
>  1 file changed, 12 insertions(+), 2 deletions(-)
> 
> diff --git a/src/gallium/drivers/freedreno/meson.build b/src/gallium/drivers/freedreno/meson.build
> index 909e16b9ed8..444e6234f38 100644
> --- a/src/gallium/drivers/freedreno/meson.build
> +++ b/src/gallium/drivers/freedreno/meson.build
> @@ -201,12 +201,22 @@ freedreno_includes = [
>    include_directories('ir3')
>  ]
>  
> +freedreno_c_args = []
> +if cc.has_argument('-Wpacked-bitfield-compat')
> +  freedreno_c_args += '-Wno-packed-bitfield-compat'
> +endif
> +
> +freedreno_cpp_args = []
> +if cpp.has_argument('-Wpacked-bitfield-compat')
> +  freedreno_cpp_args += '-Wno-packed-bitfield-compat'
> +endif
> +
>  libfreedreno = static_library(
>    'freedreno',
>    [files_libfreedreno, ir3_nir_trig_c, nir_opcodes_h],
>    include_directories : freedreno_includes,
> -  c_args : [c_vis_args],
> -  cpp_args : [cpp_vis_args],
> +  c_args : [freedreno_c_args, c_vis_args],
> +  cpp_args : [freedreno_cpp_args, cpp_vis_args],
>    dependencies : [dep_libdrm, dep_libdrm_freedreno],
>  )
>  
> -- 
> 2.13.6
> 


More information about the mesa-dev mailing list