Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2004-02-10 12:06:31


At 12:01 AM 2/10/2004, Jonathan Ultis wrote:
>Good point.
>
>Since you asked, I did some more reading. My bug report should have
>included "on 32 bit linux systems". And, it's possible to get stat to
>work for large files by using the correct defines. There could be
>linking problems if you do, but it's not likely to be a big concern. So,
>consider this a robustness patch. This will make exists () work on large
>files, even for goobers like me that don't have their compile set up to
>support large files.
>
>If you were extremely interested in supporting all configurations, there
>are also certain defines that can be set which cause large file support
>to be offered through an alternate set of function names, which can be
>useful for maintaining binary compatibility with pre-compiled libraries.
>Using that define and the alternate names would be a safe way to make
>the filesystem library work on 64bit files no matter what defines are
>used to compile. But, it's probably not worth the hassle if no one has
>complained yet.

Ah! These are the same techniques needed to correctly report file sizes for
large files. It sounds as if it isn't safe to use stat() at all without
applying them.

Since I take it that you have a large file to test on, could you please
read my http://lists.boost.org/MailArchives/boost/msg59662.php and report
the results you get? That would be helpful.

The issue isn't whether or not anyone has complained. Files that are OK
today may grow to larger sizes in the future, and we don't want silent
failures when the files cross size thresholds.

Seems like one action item here is to add an option to the Boost.Filesystem
regression tests to generate and test against large file sizes.

>The linux gazette article at www.linuxgazette.com/issue67/tag/13.html
>was interesting, if you want to follow up on this. But, it basically
>said to read info on libc and look for LFS or large file support. Doing
>so was also interesting.

Thanks! That information is essentially the same as reported here by a
couple of people in the discussion about how to report the size of large
files correctly, but it is good to have conformation.

It may take me awhile to workout all the wrinkles, but I'll be actively
working on Boost.Filesystem issues over the next several weeks.

--Beman


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk