windows: don't define strtoll for 32-bit builds
authorVincent Fu <vincent.fu@samsung.com>
Fri, 28 Jun 2024 22:12:09 +0000 (18:12 -0400)
committerVincent Fu <vincent.fu@samsung.com>
Fri, 28 Jun 2024 22:48:43 +0000 (18:48 -0400)
Our 32-bit Windows Cygwin builds started failing because one of the
libraries they require now defines strtoll when fio already defines
strtoll. To avoid this, don't define strtoll for 32-bit Windows builds.

Failed build: https://github.com/axboe/fio/actions/runs/9718276970/job/26825784199

Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
os/windows/posix.c

index a47223daaf761e0a5ae5f0843195ea93de62d011..2ce18b8bdb8dae781f52dcae15d4393bd184d34f 100644 (file)
@@ -873,10 +873,12 @@ ssize_t writev(int fildes, const struct iovec *iov, int iovcnt)
        return bytes_written;
 }
 
+#ifndef _WIN32
 long long strtoll(const char *restrict str, char **restrict endptr, int base)
 {
        return _strtoi64(str, endptr, base);
 }
+#endif
 
 int poll(struct pollfd fds[], nfds_t nfds, int timeout)
 {