8#ifndef INCLUDED_BDLS_FILESYSTEMUTIL_UNIXPLATFORM
9#define INCLUDED_BDLS_FILESYSTEMUTIL_UNIXPLATFORM
222#include <bsls_platform.h>
224#if defined(BSLS_PLATFORM_OS_UNIX)
230 #if defined(BSLS_PLATFORM_OS_AIX) \
231 && defined(BSLS_PLATFORM_CPU_32_BIT) \
232 && defined(_LARGE_FILE)
234 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
238 #elif defined(BSLS_PLATFORM_OS_AIX) \
239 && defined(BSLS_PLATFORM_CPU_32_BIT)
241 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF64 1
245 #elif defined(BSLS_PLATFORM_OS_AIX) \
246 && defined(BSLS_PLATFORM_CPU_64_BIT)
248 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
252 #elif defined(BSLS_PLATFORM_OS_CYGWIN)
254 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
258 #elif defined(BSLS_PLATFORM_OS_DARWIN)
260 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
264 #elif defined(BSLS_PLATFORM_OS_FREEBSD)
266 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
270 #elif defined(BSLS_PLATFORM_OS_LINUX) \
271 && defined(BSLS_PLATFORM_CPU_32_BIT) \
272 && defined(_FILE_OFFSET_BITS) \
273 && _FILE_OFFSET_BITS == 64
275 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
279 #elif defined(BSLS_PLATFORM_OS_LINUX) \
280 && defined(BSLS_PLATFORM_CPU_32_BIT) \
281 && defined(_LARGEFILE64_SOURCE)
283 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF64 1
287 #elif defined(BSLS_PLATFORM_OS_LINUX) \
288 && defined(BSLS_PLATFORM_CPU_32_BIT)
290 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_32_BIT_OFF 1
294 #elif defined(BSLS_PLATFORM_OS_LINUX) \
295 && defined(BSLS_PLATFORM_CPU_64_BIT)
297 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
301 #elif defined(BSLS_PLATFORM_OS_SUNOS) \
302 && defined(BSLS_PLATFORM_CPU_32_BIT) \
303 && defined(_FILE_OFFSET_BITS) \
304 && _FILE_OFFSET_BITS == 64
306 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
310 #elif defined(BSLS_PLATFORM_OS_SUNOS) \
311 && defined(BSLS_PLATFORM_CPU_32_BIT) \
312 && defined(_LARGEFILE64_SOURCE)
314 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF64 1
318 #elif defined(BSLS_PLATFORM_OS_SUNOS) \
319 && defined(BSLS_PLATFORM_CPU_32_BIT)
321 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_32_BIT_OFF 1
325 #elif defined(BSLS_PLATFORM_OS_SUNOS) \
326 && defined(BSLS_PLATFORM_CPU_64_BIT)
328 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
332 #elif defined(BSLS_PLATFORM_OS_SOLARIS) \
333 && defined(BSLS_PLATFORM_CPU_32_BIT) \
334 && defined(_FILE_OFFSET_BITS) \
335 && _FILE_OFFSET_BITS == 64
337 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
341 #elif defined(BSLS_PLATFORM_OS_SOLARIS) \
342 && defined(BSLS_PLATFORM_CPU_32_BIT) \
343 && defined(_LARGEFILE64_SOURCE)
345 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF64 1
349 #elif defined(BSLS_PLATFORM_OS_SOLARIS) \
350 && defined(BSLS_PLATFORM_CPU_32_BIT)
352 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_32_BIT_OFF 1
356 #elif defined(BSLS_PLATFORM_OS_SOLARIS) \
357 && defined(BSLS_PLATFORM_CPU_64_BIT)
359 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_64_BIT_OFF 1
362 #error "'bdls_filesystemutil_unixplatform.h' does not support this Unix."
365#if defined(BSLS_PLATFORM_OS_SOLARIS) || \
366 defined(BSLS_PLATFORM_OS_AIX) || \
367 defined(BSLS_PLATFORM_OS_LINUX)
369 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_STAT_NS_MEMBER st_mtim.tv_nsec
371#elif defined(BSLS_PLATFORM_OS_DARWIN)
373 #define BDLS_FILESYSTEMUTIL_UNIXPLATFORM_STAT_NS_MEMBER st_mtimespec.tv_nsec
#define BSLS_IDENT(str)
Definition bsls_ident.h:195