Add sys/time.h and time.h header detection to resolve FTBFS.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/6/head
Slávek Banko 3 years ago
parent 355f00c2bd
commit bda2d7559f
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -22,6 +22,7 @@ include( FindPkgConfig )
include( CheckFunctionExists )
include( CheckSymbolExists )
include( CheckIncludeFile )
include( CheckIncludeFiles )
include( CheckIncludeFileCXX )
include( CheckLibraryExists )
include( CheckCSourceCompiles )

@ -35,6 +35,9 @@ find_package( X11 )
check_include_file( stdint.h HAVE_STDINT_H )
check_include_file( inttypes.h HAVE_INTTYPES_H )
check_include_file( "sys/time.h" HAVE_SYS_TIME_H )
check_include_files( "sys/time.h;time.h" TIME_WITH_SYS_TIME )
##### check for GnuTLS or OpenSSL( default )

@ -22,6 +22,12 @@
/* Defined if you have <inttypes.h> header */
#cmakedefine HAVE_INTTYPES_H 1
// Defined to 1 if you have 'sys/time.h' header
#cmakedefine HAVE_SYS_TIME_H 1
// Defined to 1 if 'time.h' header can be included together with 'sys/time.h'
#cmakedefine TIME_WITH_SYS_TIME 1
/* Disable features for LIVECD use */
#cmakedefine LIVECD 1

@ -496,6 +496,9 @@ AC_CHECK_FUNCS(strchr memcpy getopt_long)
AC_CHECK_HEADERS(unistd.h string.h libiberty.h)
AC_HEADER_STAT
AC_HEADER_TIME
AC_CHECK_HEADERS(sys/time.h)
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_TYPE_SIZE_T

@ -44,7 +44,12 @@
#include <tdeio/netaccess.h>
#include <tdelocale.h>
#include <sys/time.h>
#if defined(HAVE_SYS_TIME_H)
# include <sys/time.h>
#endif
#if defined(TIME_WITH_SYS_TIME)
# include <time.h>
#endif
/* Linux-specific includes */
#include <dirent.h>

Loading…
Cancel
Save