mirror of
https://github.com/facebook/zstd.git
synced 2025-07-29 11:21:22 +03:00
zstd: Don't use utime on Linux
utime is deprecated by POSIX 2008 and optionally not available with uClibc-ng. Got rid of a few useless headers in timefn.h. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
@ -25,12 +25,17 @@ extern "C" {
|
||||
#include <stdio.h> /* fprintf */
|
||||
#include <sys/types.h> /* stat, utime */
|
||||
#include <sys/stat.h> /* stat, chmod */
|
||||
#if defined(_MSC_VER)
|
||||
#if defined(_WIN32)
|
||||
# include <sys/utime.h> /* utime */
|
||||
# include <io.h> /* _chmod */
|
||||
#else
|
||||
# include <unistd.h> /* chown, stat */
|
||||
#if PLATFORM_POSIX_VERSION < 200809L
|
||||
# include <utime.h> /* utime */
|
||||
#else
|
||||
# include <fcntl.h> /* AT_FDCWD */
|
||||
# include <sys/stat.h> /* utimensat */
|
||||
#endif
|
||||
#endif
|
||||
#include <time.h> /* clock_t, clock, CLOCKS_PER_SEC, nanosleep */
|
||||
#include "mem.h" /* U32, U64 */
|
||||
|
Reference in New Issue
Block a user