bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: getconf LFS_CFLAGS


From: Roland McGrath
Subject: Re: getconf LFS_CFLAGS
Date: Sun, 5 Aug 2001 14:49:04 -0400 (EDT)

> `getconf LFS_CFLAGS`x = x.  I realize that the 64 bit functions are not
> yet implemented, however, this also has the unfortunate side effect that
> programs which use only off_t and libstore see sizeof (off_t) == 4.
> What is the Right Thing to do?

I'm not really clear on what you're asking.

>From what I can see in the libc sources (not being able to run anything),
it looks like confstr(_CS_LFS_CFLAGS) ought to return "-D_FILE_OFFSET_BITS=64".

The current libc for Hurd should support LFS mode at the source level as is
done on Linux.  That is, you can use types off64_t et al and *64 functions,
or you can compile your application with -D_FILE_OFFSET_BITS=64.  (Large
file support is not there in the Hurd, but libc implements the 64-bit
interfaces and checks for overflow of 32 bit sizes.)  The only real benefit
to doing this is that the program binary you make now won't need to be
recompiled to support large files later on when libc and the Hurd servers
support them, because the libc ABI won't have to change for that.  (But in
reality I expect the ABI will change for other reasons before large file
support gets implemented.)

None of this seems relevant to pure users of libstore, however.
The `off_t' type is not part of the libstore interface (any more).
The type `store_offset_t' (64 bits) is what's now used in the libstore
function interfaces.

Actually, I think you will break libstore if you try to compile against
it using -D_FILE_OFFSET_BITS=64, because it uses `off_t' internally in
places where the 32-bit type is required.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]