[Intel-gfx] [PATCH i-g-t 12/12] RFC: meson build system support

Jani Nikula jani.nikula at linux.intel.com
Mon Sep 4 13:11:17 UTC 2017


On Sat, 02 Sep 2017, Daniel Vetter <daniel.vetter at ffwll.ch> wrote:
> +if cc.has_member('struct sysinfo', 'totalram',
> +		prefix : '#include <sys/sysinfo.h>')
> +	config_h.set('HAVE_STRUCT_SYSINFO_TOTALRAM', 1)
> +endif
> +
> +add_project_arguments('-D_GNU_SOURCE', language : 'c')

Just something that caught my eye that bit me in the past. The project
arguments are *not* passed on to feature tests such as
cc.has_member(). I don't think it matters in this case, but you'll want
to #define _GNU_SOURCE in the prefix if you're testing for GNU
stuff. Otherwise you may end up using compat versions. Just a heads up,
that's all.

BR,
Jani.


-- 
Jani Nikula, Intel Open Source Technology Center


More information about the Intel-gfx mailing list