Boost logo

Boost Testing :

From: Christopher Cambly (ccambly_at_[hidden])
Date: 2008-01-15 21:47:30

> > Jonathan Turkanis <turkanis_at_[hidden]> wrote on 12/01/2008 03:27:42
> >
> >> Jonathan Turkanis <turkanis_at_[hidden]>
> >
> >>>> While we're on the subject of compiler flags for large file support,
> >>>> there's another part of the Iostreams library that I have attempted
> >>>> configure for IBM. I've read the documentation, but it would be
> > I guess if I was to tentatively suggest something for AIX in general it
> > would be _LARGE_FILE_API
> I didn't run into that one.

Forget I mentioned it :-) I spoke with the AIX developers today and they
said applications shouldn't ever use _LARGE_FILE_API directly themselves;
the macro just dictates whether the various *64 file API's and types are
visible or not. But that macro has other dependencies as well.

Here is the response from them to your original query:
So, as for what the Boost code should use, note that the presence of
_LARGE_FILES controls whether or not the file handling API's map to their
counterparts -- in other words, it serves the same purpose that the coded
conditional does below. (meaning the coded conditional in your code)

In other words, if they simply always did this for AIX:
      # define BOOST_IOSTREAMS_FD_SEEK lseek

After including the standard header files, that's all taken care of because
if he has defined _LARGE_FILES, then lseek is already defined to lseek64.
If _LARGE_FILES is not defined, then lseek is just lseek. Also
_LARGE_FILES defines off_t to be a long long instead of a long, so if you
always just use the names "off_t" and "lseek" (and so on), the types will
be correct for either defining or not defining _LARGE_FILES.

The best info on this is in the AIX pubs, in the "Writing Programs That
Access Large Files" page.


I'm not sure whether or not this is a satisfactory response to your
question. The recommendation being that on AIX let the system headers
determine the function to be called. But...If I read the above correctly,
it also seems like if you really want to do it in the Boost, the code as
you have it now in SVN should work.

Chris Cambly
XL C/C++ Compiler Development

Boost-testing list run by mbergal at