Do we need sys_open() et al (_LARGEFILE64_SOURCE and open64())?
Jeremy Allison
jra at samba.org
Sun Mar 25 09:19:40 MDT 2012
On Sun, Mar 25, 2012 at 01:55:04PM +1100, Andrew Bartlett wrote:
>
> While we are thinking about sys_ wrappers, I wondered if we still really
> needed the sys_*() wrappers for open64 etc?
>
> man feature_test_macros(7) says:
>
> _LARGEFILE64_SOURCE
> Expose definitions for the alternative API specified by the LFS
> (Large File Summit) as a "transitional extension" to the Single UNIX
> Specification. (See http://opengroup.org/platform/lfs.html.) The
> alternative API consists of a set of new objects (i.e., functions and
> types) whose names are suffixed with "64" (e.g., off64_t versus off_t,
> lseek64() versus lseek(), etc.). New programs should not employ this
> interface; instead _FILE_OFFSET_BITS=64 should be employed.
>
> _FILE_OFFSET_BITS
> Defining this macro with the value 64 automatically converts
> references to 32-bit functions and data types related to file I/O and
> file system operations into references to their 64-bit counterparts.
>
> As such, are there any systems that we need that have
> _LARGEFILE64_SOURCE but not _FILE_OFFSET_BITS?
>
> Thanks,
Oooh. That's a really good point. It would simplify
those interfaces. How do we find out if the open64
etc. are still being used on platforms ?
Jeremy.
More information about the samba-technical
mailing list