From 2829e177430f6f190447bd52563949d2c0ce377b Mon Sep 17 00:00:00 2001 From: Kleis Auke Wolthuizen Date: Mon, 7 Aug 2023 22:57:00 +0200 Subject: [PATCH] Fix build with musl 1.2.4 (#3755) --- src/pipeline.cc | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/pipeline.cc b/src/pipeline.cc index 2e6d87691..47f6bf9e5 100644 --- a/src/pipeline.cc +++ b/src/pipeline.cc @@ -20,18 +20,15 @@ #include "operations.h" #include "pipeline.h" -#if defined(WIN32) +#ifdef _WIN32 #define STAT64_STRUCT __stat64 #define STAT64_FUNCTION _stat64 -#elif defined(__APPLE__) -#define STAT64_STRUCT stat -#define STAT64_FUNCTION stat -#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) -#define STAT64_STRUCT stat -#define STAT64_FUNCTION stat -#else +#elif defined(_LARGEFILE64_SOURCE) #define STAT64_STRUCT stat64 #define STAT64_FUNCTION stat64 +#else +#define STAT64_STRUCT stat +#define STAT64_FUNCTION stat #endif class PipelineWorker : public Napi::AsyncWorker {