This is the mail archive of the
glibc-linux@ricardo.ecn.wfu.edu
mailing list for the glibc project.
Large File Support in glibc 2.1?
- To: glibc-linux@ricardo.ecn.wfu.edu
- Subject: Large File Support in glibc 2.1?
- From: Ali Bahrami <ali@rsinc.com>
- Date: Tue, 22 Jun 1999 11:05:52 -0600 (MDT)
- Reply-To: glibc-linux@ricardo.ecn.wfu.edu
Having heard that GlibC 2.1 has support for files with 64-bit offsets
and having recently installed Red Hat 6 Linux which is based on that
library, I decided to enable large file support for my application
(an application which already handles 64-bit offsets under Solaris,
Dec Unix, IRIX, and HP-UX).
I compiled everything with "-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
and was able to link without error. At runtime, I get a segfault,
which turns out to be in
#0 0x408eb1f1 in _IO_old_file_close_it (fp=0x8190a20) at oldfileops.c:143
#1 0x408e7595 in _IO_old_fclose (fp=0x8190a20) at oldiofclose.c:43
At this point, it looks like a file opened with the 64-bit open is being
closed with a 32-bit close, or so I infer from the "old" in the function
names. In solving this problem, I can see the following possibilities:
1) I have built/linked my program incorrectly for glibc.
2) The glibc 2.1 shipping with RedHat 6 has problems in this
area.
This leads to my real problem --- I have been unable to dig up any
information about glibc 2.1's large file support at all. Newsgroups,
and extensive web searching have yielded next to no information on this
topic. I freely admit that this is probably a simple RTFM problem, if
I could just find the right stuff to read...
If anyone in this group can point me at documentation of any type
describing how complete glibc 2.1's support for large files is
and/or how one should proceed in using it, I would greatly appreciate
it. Thanks...
- Ali