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

Re: [Xen-devel] build fixes



Keir Fraser wrote:
On 12/01/2010 17:22, "Ian Jackson" <Ian.Jackson@xxxxxxxxxxxxx> wrote:

-    seek_ret = lseek64(fd, i << PAGE_SHIFT, SEEK_SET);
+    seek_ret = lseek(fd, i << PAGE_SHIFT, SEEK_SET);
This is just wrong.  It will break on >2G files.

We build everything under tools/ with LFS support enabled, so off_t is 64
bits even in 32-bit environments. FYI The bits to enable LFS support are in
tools/Rules.mk.

According to the lseek64 man page, for 32-bit architectures to have 64-bit off_t, you need:

#define _FILE_OFFSET_BITS 64

Which, as far as I know, isn't set. LFS just makes lseek64 available (without it, the function doesn't exist).


Patrick

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.