Commit 48d7f027 authored by Jean-Paul Saman's avatar Jean-Paul Saman

configure.ac: workaround gettimeofday not being found.

Even when sys/time.h exists the function gettimeofday is not picked up
by this configure script. The example/decode_mpeg.c program compiles
fine when sys/time.h is present.
parent 2e81f509
......@@ -56,8 +56,8 @@ else
fi
dnl Check for headers
AC_CHECK_HEADERS(stdint.h inttypes.h)
AC_CHECK_FUNCS(gettimeofday)
AC_CHECK_HEADERS(stdint.h inttypes.h getopt.h sys/time.h)
dnl AC_CHECK_FUNCS([gettimeofday])
AC_CHECK_HEADERS(sys/socket.h, [ac_have_sys_socket_h=yes])
AM_CONDITIONAL(HAVE_SYS_SOCKET_H, test "${ac_have_sys_socket_h}" = "yes")
......
......@@ -32,7 +32,10 @@
#include <string.h>
#include <errno.h>
#include <sys/types.h>
#ifdef HAVE_SYS_TIME_H
#define HAVE_GETTIMEOFDAY 1
#include <sys/time.h>
#endif
#include <time.h>
#include <unistd.h>
#include <fcntl.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