"Michelangelo Nottoli" <[EMAIL PROTECTED]> wrote: > ... > #if defined(__unix__) || defined(__sun__) > ...call fopen64 > #else > ..call fopen > #endif
This is unreliable, because __unix__ may not always be defined, and __sun__ includes older (32-bit only) versions of Solaris as well as the old SunOS 4.x. Believe it or not, not everyone in the world use the latest OS versions. It costs money to upgrade and many sites are reluctant to change if things are running well. Solaris is not the only platform on which >2GB files is an issue., so there is also the broader issue of making >2GB file support portable. This stuff should all be encapsulated into the configure script to detect the availability of such features (and allow override via command line options). I also discovered recently in the libmp4v2 sources of the faad decoder package, that it had some hacks around the fact that Linux's fopen doesn't work with large files (it uses the O_LARGEFILE definition in <fcntl.h> as a means to check for large file support), and change to using open() with the O_LARGEFILE flag and then fdopen() to get a stdio stream. This however, doesn't work correctly on IRIX 6.5 where O_LARGEFILE is also defined... Just citing an example that there is a potential can of worms in this. My 2 cents. -Ti -- R 1 3 5 Ti Kan |_|_|_| http://www.amb.org/ti | | | Vorsprung durch Technik 2 4 6 _______________________________________________ mp3encoder mailing list [EMAIL PROTECTED] http://minnie.tuhs.org/mailman/listinfo/mp3encoder
