GNOME Bugzilla – Bug 142209
[build] Large file support broken
Last modified: 2005-08-25 23:43:08 UTC
The flags for large file support (-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64) are added to GST_PKG_CFLAGS, which aren't actually used for compiling the core elements. Hence, filesrc and filesink don't support files > 2GB now. Which GST_*_CFLAGS should these go in? a) should all our code in core be compiled with this ? b) should all our plugins be compiled with this ? c) should external plugins be compiled with this ? d) should all apps be compiled with this ?
Is this still a blocker? I think we somehow fixed this and it can be closed now, no?
no, it's not fixed, it's worked around in the old way, and someone just needs to look into it and decide how it should be done. I have no clue about large file support.
The -D_LARGEFILE_SOURCE and -D_FILE_OFFSET_BITS=64 flags should be used when compiling all of our code, but not put into the pkg-config files. The glibc API depends on those defines, but the ABI does not.
Is this still a blocker?
I don't consider it a blocker, nobody has yet reported a real problem due to it. I propose we change it straight after 0.8.4 so we have time to address bugs that could come due to changing it.
what's the status of this one ? has it been changed in 0.8.4 ?, later ?
please don't milestone to 0.8.8 if there is no solution
Er, there is a solution. We should use the flags when we compile our own code (because we know it's compatible with largefile-glibc), but we should not export this in any way (because otherwise it forces everyone else to be compatible). Arguably, by putting this in our .pc files, we already screwed up, and should wait for 0.9 to fix it.
Still in the .pc file in 0.9. Ping, interested parties? Now would be the time to close this bug one way or another.
Created attachment 49990 [details] small test program that seeks to file position and hexdumps buffer Just for reference, a small test program that seeks to the specified file position of a file and hexdumps the first buffer it gets from there (just to make sure seeking beyond 2GB works).
2005-07-30 Tim-Philipp Muller <tim at centricular dot net> * configure.ac: Use AC_SYS_LARGEFILE, which will set _FILE_OFFSET_BITS=64 and _LARGEFILE_SOURCE in config.h as required. Do not export those flags in our .pc files any longer (#142209). Remove unused GST_DISABLE_OMEGA_COTHREADS stuff. * gst/elements/gstfilesink.c: (gst_file_sink_class_init), (gst_file_sink_do_seek), (gst_file_sink_event), (gst_file_sink_get_current_offset), (gst_file_sink_render): Redo seek/tell calls with large file support in mind; add some debugging messages; add log message that tells us when large file support is unavailable or not enabled for some reason. * gst/elements/gstfilesrc.c: (gst_file_src_class_init): Add log message that tells us when large file support is unavailable or not enabled for some reason.