>2GB files with python
ethan mindlace fremen
mindlace at imeme.net
Fri Mar 3 03:36:40 EST 2000
ethan mindlace fremen wrote:
>
> I've got a file >2GB in Linux. I've enabled large files[1] and ls
> reports the size as 2,990,538,752 bytes.
>
> os.path.getsize() reports the size as -1,304,428,544.
>
> I compiled python with these flags:
> #define _LARGEFILE_SOURCE 1
> #define _LARGEFILE_64_SOURCE 1
> #define _FILE_OFFSET_BITS 64
>
> although it does say that off_t is 4, long is 4 too and long_long is 8.
>
> What am I doing wrong?
>
> thanks,
> --
> ethan mindlace fremen - mindlace at imeme.net
> good design is as close as I want to get to ideology.
>
> --
> http://www.python.org/mailman/listinfo/python-list
sorry, [1] means kernel 2.3.47 and libc6 2.1.13-5 (debian potato)
More information about the Python-list
mailing list