Hi Chet, Chet Ramey wrote:
> Compile and run the attached program. If it prints out `4', which it does > on all of the Debian systems I've tried, file offsets are limited to 32 > bits, and accessing files greater than 2 GB is going to be unreliable. off_t is typedef'd to off64_t if you compile with -D_FILE_OFFSET_BITS=64. The AC_SYS_LARGEFILE autoconf macro is supposed to cause bash to be built with -D_FILE_OFFSET_BITS=64 (and seems to work that way here, based on the result of "eu-readelf -s /bin/bash | grep open"). Jean-François is using a 64-bit architecture, where _FILE_OFFSET_BITS=64 is the default, anyway. So I fear the problem is somewhere else. (Maybe an "int" is used as an offset somewhere.) Hope that helps, Jonathan