meson.build: Change c_std to gnu99
Since commit 301a556b8ece ("add fps reporting") the <time.h> header
is included, which causes build failures with c99 extension on ARM32:
../common.c: In function 'get_time_ns':
../common.c:376:18: error: storage size of 'tv' isn't known
struct timespec tv;
^~
../common.c:377:16: error: 'CLOCK_MONOTONIC' undeclared (first use in this function)
clock_gettime(CLOCK_MONOTONIC, &tv);
Change c_std to gnu99 to fix the build error as explained at:
https://gcc-help.gcc.gnu.narkive.com/8xCaKI6r/problem-with-struct-timespec-and-c99-standard
c99 has been used since commit 6cbd03ab9406 ("Makefile.am: Add -std=c99 to
CFLAGS") to fix the following mips64el build failure:
"cube-tex.c:230:2: note: use option -std=c99 or -std=gnu99 to compile your code"
Use c_std=gnu99 to make both mips64el and ARM32 happy.
Signed-off-by: Fabio Estevam <festevam@gmail.com>
Fabio Estevam
4 years ago
25 | 25 | version : '0.0.1', |
26 | 26 | license : 'MIT', |
27 | 27 | meson_version : '>= 0.47', |
28 | default_options : ['c_std=c99', 'warning_level=2'] | |
28 | default_options : ['c_std=gnu99', 'warning_level=2'] | |
29 | 29 | ) |
30 | 30 | |
31 | if get_option('c_std') != 'c99' | |
32 | error('c_std must be c99') | |
31 | if get_option('c_std') != 'gnu99' | |
32 | error('c_std must be gnu99') | |
33 | 33 | endif |
34 | 34 | |
35 | 35 | sources = files( |