From: pk on
Alan Curry wrote:

> In article <hm65o5$qq3$1(a)speranza.aioe.org>, pk <pk(a)pk.invalid> wrote:
> |Apparently "gzip" is (or was) such a software on some systems.
>
> Look at the timestamps on the releases (from ftp.gnu.org):
>
> -rw-r--r-- 1 1003 65534 220623 Aug 20 1993 gzip-1.2.4.tar.gz
> -rw-r--r-- 1 1003 65534 220774 Feb 03 1999 gzip-1.2.4a.tar.gz
>
> Between 1993 and 1999 there was no gzip release. At the beginning of that
> time frame, files larger than 2G were not really common, and OS support
> for them was still under development. It would have been almost impossible
> for gzip to support large files at the time 1.2.4 was released.
>
> But by the time the next release came, large file support at the libc
> level was basically universal, and gzip was one of the last stragglers
> that didn't make use of it (unless the OS vendor included a patched gzip,
> or the OS was full-on 64-bit-only in which case it was never an issue)
>
> Actually, on taking a closer look, 1.2.4a didn't even include any code
> changes, so it didn't support large files either. gzip didn't catch up
> until 1.3, released in late 2001!

Thank you! Now I understand the context in which that use of cat makes
sense.

From: Sven Mascheck on
Alan Curry wrote:

> It would have been almost impossible for gzip to support large files at
> the time 1.2.4 was released.

I was too quick with "bug".

> Actually, on taking a closer look, 1.2.4a didn't even include any code
> changes, so it didn't support large files either.

I haven't tried to find out where the toolkit might fail, but ironically
recompiling 1.2.4 with just having added "-D_FILE_OFFSET_BITS=64" to the
CFLAGS allows gzip to compress a 2G file. At least with a current libc,

__lxstat64(3, "./large", 0x806f520 <unfinished ...>
SYS_lstat64(0x808f9c0, 0x806f520, 0xb7f95ff4, 0x808f9c0, 0x80a460c) = 0
<... __lxstat64 resumed> ) = 0
From: pk on
Sven Mascheck wrote:

> Alan Curry wrote:
>
>> It would have been almost impossible for gzip to support large files at
>> the time 1.2.4 was released.
>
> I was too quick with "bug".
>
>> Actually, on taking a closer look, 1.2.4a didn't even include any code
>> changes, so it didn't support large files either.
>
> I haven't tried to find out where the toolkit might fail, but ironically
> recompiling 1.2.4 with just having added "-D_FILE_OFFSET_BITS=64" to the
> CFLAGS allows gzip to compress a 2G file. At least with a current libc,

Yes, I think that is expected, since defining that macro silently replaces
all the "normal" calls with the 64-bit versions, so a recompilation should
be all that's needed. I found this page helpful to understand the whole
large file support thing:

http://www.suse.de/~aj/linux_lfs.html