From f5fee949e3dcbe9cc6761927f69057196990e1f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9B=D0=B5=D0=BE=D0=BD=D0=B8=D0=B4=20=D0=AE=D1=80=D1=8C?= =?UTF-8?q?=D0=B5=D0=B2=20=28Leonid=20Yuriev=29?= Date: Thu, 13 Oct 2022 17:30:43 +0300 Subject: [PATCH] =?UTF-8?q?mdbx:=20=D0=BF=D0=BE=D1=87=D0=B8=D0=BD=D0=BA?= =?UTF-8?q?=D0=B0=20=D1=81=D0=B1=D0=BE=D1=80=D0=BA=D0=B8=20=D0=B4=D0=BB?= =?UTF-8?q?=D1=8F=20=D1=81=D1=82=D0=B0=D1=80=D1=8B=D1=85=20=D0=B2=D0=B5?= =?UTF-8?q?=D1=80=D1=81=D0=B8=D0=B9=20glibc=20=D0=BF=D0=BE=D1=81=D0=BB?= =?UTF-8?q?=D0=B5=20=D0=B7=D0=B0=D0=B4=D0=B5=D0=B9=D1=81=D1=82=D0=B2=D0=BE?= =?UTF-8?q?=D0=B2=D0=B0=D0=BD=D0=B8=D1=8F=20`fcntl64()`.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/osal.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/osal.h b/src/osal.h index 6876911b..017abcb4 100644 --- a/src/osal.h +++ b/src/osal.h @@ -431,7 +431,14 @@ MDBX_MAYBE_UNUSED static __inline void jitter4testing(bool tiny); #define MDBX_F_SETLK F_SETLK64 #define MDBX_F_SETLKW F_SETLKW64 #define MDBX_F_GETLK F_GETLK64 +#if (__GLIBC_PREREQ(2, 28) && \ + (defined(__USE_LARGEFILE64) || defined(__LARGEFILE64_SOURCE) || \ + defined(_USE_LARGEFILE64) || defined(_LARGEFILE64_SOURCE))) || \ + defined(fcntl64) #define MDBX_FCNTL fcntl64 +#else +#define MDBX_FCNTL fcntl +#endif #define MDBX_STRUCT_FLOCK struct flock64 #ifndef OFF_T_MAX #define OFF_T_MAX UINT64_C(0x7fffFFFFfff00000)