commit: 7b47cf64b5db7ce03f7a41e24b09182961444197 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> AuthorDate: Wed Feb 28 19:09:44 2018 +0000 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> CommitDate: Wed Feb 28 19:09:44 2018 +0000 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=7b47cf64
script/rsync-generation/hashgen: allow compilation on Darwin scripts/rsync-generation/hashgen.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/rsync-generation/hashgen.c b/scripts/rsync-generation/hashgen.c index b2ba8b0f5a..833c8e7205 100644 --- a/scripts/rsync-generation/hashgen.c +++ b/scripts/rsync-generation/hashgen.c @@ -99,6 +99,10 @@ hex_hash(char *out, const unsigned char *buf, const int length) static inline void update_times(struct timeval *tv, struct stat *s) { +#ifdef __MACH__ +# define st_mtim st_mtimespec +# define st_atim st_atimespec +#endif if (tv[1].tv_sec < s->st_mtim.tv_sec || (tv[1].tv_sec == s->st_mtim.tv_sec && tv[1].tv_usec < s->st_mtim.tv_nsec / 1000))