Commit e85482ba authored by Martin Storsjö's avatar Martin Storsjö

meson: Check for io.h and include it in dav1d.c if available

With MSVC, io.h holds the declaration of the isatty function.

This fixes this warning:
../tools/dav1d.c(63): warning C4013: 'isatty' undefined; assuming extern returning int
parent 67f33e68
......@@ -124,6 +124,10 @@ if cc.check_header('unistd.h')
cdata.set('HAVE_UNISTD_H', 1)
endif
if cc.check_header('io.h')
cdata.set('HAVE_IO_H', 1)
endif
# Function checks
......
......@@ -36,6 +36,9 @@
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#ifdef HAVE_IO_H
# include <io.h>
#endif
#include "dav1d/data.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment