[Ecls-list] largefile support and 64-bit foreign types on 32-bit platforms

Stelian Ionescu sionescu at common-lisp.net
Mon Jul 21 19:38:57 UTC 2008


On Mon, 2008-06-02 at 00:17 +0200, Stelian Ionescu wrote:
> In order to be able to be able to have file offsets larger than 32
> bit(for files larger than 2 GB) some OSes(Linux and IIRC Solaris too)
> require to compile with special flags: on Linux those are
> -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 . When
> those flags are enabled several C types become promoted from 32-bit to
> 64-bit, more notably off_t, several structs change layout becoming
> larger(struct stat for instance) and alternative implementations of
> several syscalls get activated through GCC magic: stat() and readdir()
> for instance.
> 
> I think that ECL should always be compiled with largefile support on
> Linux and that two additional 64-bit FFI types should be added:
> :long-long and :unsigned-long-long. Read and write operations on those
> types would be done with two consecutive 32-bit operations, just like
> SBCL, Clisp or GCC do.

any thoughts on this ?
currently, if I try to open a 5 GB file, I get a FILE-ERROR

-- 
Stelian Ionescu a.k.a. fe[nl]ix
Quidquid latine dictum sit, altum videtur.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <https://mailman.common-lisp.net/pipermail/ecl-devel/attachments/20080721/72045794/attachment.sig>


More information about the ecl-devel mailing list