lfs confusion

John Hunter jdhunter at ace.bsd.uchicago.edu
Thu Sep 23 23:06:16 CEST 2004

>>>>> "Andrew" == Andrew Dalke <adalke at mindspring.com> writes:

    Andrew> You're beyond my knowledge there.  I thought that Python
    Andrew> did the check automatically and didn't need the CLAGS= ...

    Andrew> I compile from CVS source without special commands and it
    Andrew> Just Works.

Well, the reason I have embarked on this path is to find out if my
zope has LFS support or not.  Your post gave me the inspiration to
just dig through the zope configure script and find out what they were
doing (I've hit the 2GB limit one too many times with the zobd to let
myself do it again).

In inst/configure.py, I found 

def test_largefile():
    f = open(sys.argv[0], 'r')
        # 2**31 == 2147483648
    except (IOError, OverflowError):
    if OK:
    ...else raise an error message...

I pass the 2**31 test but fail your sys.maxint * 3L

>>> fd = file('/dev/null')
>>> fd.seek(2147483649L)
>>> fd.seek(sys.maxint * 3L)
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
OverflowError: long int too large 

It appears, that as far as zope if concerned, I can exceed the 2GB
limit and so I should be safe, hopefully up to 

>>> sys.maxint/1.e9

Should cover me for a while <wink>

Thanks for your help,

More information about the Python-list mailing list