summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabio Estevam <festevam@gmail.com>2020-03-30 21:30:15 -0300
committerFabio Estevam <festevam@gmail.com>2020-03-31 22:20:03 -0300
commit178cb5904f4f6c2482bceb4e3b59990fa6ed5878 (patch)
tree7c4f33d8518334b5263aa463c9883325730abd42
parent28c3af8445a14b4920a190157e660f35d2e44368 (diff)
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>
-rw-r--r--meson.build6
1 files changed, 3 insertions, 3 deletions
diff --git a/meson.build b/meson.build
index b8131db..4fca2f2 100644
--- a/meson.build
+++ b/meson.build
@@ -26,11 +26,11 @@ project(
version : '0.0.1',
license : 'MIT',
meson_version : '>= 0.47',
- default_options : ['c_std=c99', 'warning_level=2']
+ default_options : ['c_std=gnu99', 'warning_level=2']
)
-if get_option('c_std') != 'c99'
- error('c_std must be c99')
+if get_option('c_std') != 'gnu99'
+ error('c_std must be gnu99')
endif
sources = files(