Define _TIME_BITS=64 on systems that define __TIMESIZE, like GNU libc.
This should be replaced by a specialized autoconf macro when one becomes available.
This commit is contained in:
@@ -1386,6 +1386,9 @@
|
|||||||
/* Define for large files, on AIX-style hosts. */
|
/* Define for large files, on AIX-style hosts. */
|
||||||
#undef _LARGE_FILES
|
#undef _LARGE_FILES
|
||||||
|
|
||||||
|
/* Number of bits in a time_t, on hosts where this is settable. */
|
||||||
|
#undef _TIME_BITS
|
||||||
|
|
||||||
/* Define to __FUNCTION__ if your compiler supports __FUNCTION__ but not
|
/* Define to __FUNCTION__ if your compiler supports __FUNCTION__ but not
|
||||||
__func__ */
|
__func__ */
|
||||||
#undef __func__
|
#undef __func__
|
||||||
|
20
configure
vendored
20
configure
vendored
@@ -19341,7 +19341,9 @@ fi
|
|||||||
|
|
||||||
done
|
done
|
||||||
#
|
#
|
||||||
# Check for large file support.
|
# Check for large file and 64-bit time support.
|
||||||
|
# GNU libc only allows setting _TIME_BITS when FILE_OFFSET_BITS is also set.
|
||||||
|
# GNU libc defines __TIMESIZE on systems where _TIME_BITS can be set.
|
||||||
#
|
#
|
||||||
# Check whether --enable-largefile was given.
|
# Check whether --enable-largefile was given.
|
||||||
if test ${enable_largefile+y}
|
if test ${enable_largefile+y}
|
||||||
@@ -19547,6 +19549,22 @@ rm -rf conftest*
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if test X"$ac_cv_sys_file_offset_bits" = X"yes"; then
|
||||||
|
ac_fn_check_decl "$LINENO" "__TIMESIZE" "ac_cv_have_decl___TIMESIZE" "
|
||||||
|
$ac_includes_default
|
||||||
|
#include <time.h>
|
||||||
|
|
||||||
|
" "$ac_c_undeclared_builtin_options" "CFLAGS"
|
||||||
|
if test "x$ac_cv_have_decl___TIMESIZE" = xyes
|
||||||
|
then :
|
||||||
|
|
||||||
|
|
||||||
|
printf "%s\n" "#define _TIME_BITS 64" >>confdefs.h
|
||||||
|
|
||||||
|
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# HP-UX may need to define _XOPEN_SOURCE_EXTENDED to expose MSG_WAITALL.
|
# HP-UX may need to define _XOPEN_SOURCE_EXTENDED to expose MSG_WAITALL.
|
||||||
# Also, HP-UX 11.23 has a broken sys/types.h when large files support
|
# Also, HP-UX 11.23 has a broken sys/types.h when large files support
|
||||||
|
13
configure.ac
13
configure.ac
@@ -2447,9 +2447,20 @@ AC_CHECK_HEADERS([procfs.h] [sys/procfs.h], [AC_CHECK_MEMBERS(struct psinfo.pr_t
|
|||||||
])]
|
])]
|
||||||
break)
|
break)
|
||||||
#
|
#
|
||||||
# Check for large file support.
|
# Check for large file and 64-bit time support.
|
||||||
|
# GNU libc only allows setting _TIME_BITS when FILE_OFFSET_BITS is also set.
|
||||||
|
# GNU libc defines __TIMESIZE on systems where _TIME_BITS can be set.
|
||||||
#
|
#
|
||||||
AC_SYS_LARGEFILE
|
AC_SYS_LARGEFILE
|
||||||
|
if test X"$ac_cv_sys_file_offset_bits" = X"yes"; then
|
||||||
|
AC_CHECK_DECL(__TIMESIZE, [
|
||||||
|
AC_DEFINE([_TIME_BITS], [64], [Number of bits in a time_t, on hosts where this is settable.])
|
||||||
|
], [], [
|
||||||
|
AC_INCLUDES_DEFAULT
|
||||||
|
#include <time.h>
|
||||||
|
])
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# HP-UX may need to define _XOPEN_SOURCE_EXTENDED to expose MSG_WAITALL.
|
# HP-UX may need to define _XOPEN_SOURCE_EXTENDED to expose MSG_WAITALL.
|
||||||
# Also, HP-UX 11.23 has a broken sys/types.h when large files support
|
# Also, HP-UX 11.23 has a broken sys/types.h when large files support
|
||||||
|
Reference in New Issue
Block a user