Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 177187 - gzcat does not actually perform gzip -dc for gzip-1.3.11
Summary: gzcat does not actually perform gzip -dc for gzip-1.3.11
Status: RESOLVED DUPLICATE of bug 175279
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-05 15:42 UTC by Gil Kloepfer
Modified: 2007-05-05 15:49 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gil Kloepfer 2007-05-05 15:42:13 UTC
The ebuild for gzip installs the symlink for gzcat, but gzcat does not actually perform "gzip -dc {file}" but rather simply runs gzip.

Reproducible: Always

Steps to Reproduce:
1. Compress a file text with gzip (creating example-file.txt.gz)
2. gzcat example-file.txt
3. also try gzcat example-file.txt.gz

Actual Results:  
2.
gzcat: example.file.txt: No such file or directory

3.
gzcat: example.file.txt.gz already has .gz suffix -- unchanged


Expected Results:  
in both cases, the uncompressed text file should have been displayed

This behavior for gzcat is actually somewhat controversial.  FreeBSD, for example, defines the behavior for gzcat that I am expecting.  This would, in my opinion, be the only reason one would create a symlink/command called "gzcat."  However, an examination of the source for gzip-1.3.11 gzip.c lines 411-428 appears to imply that this is not the "GNU standard" behavior.

The right fix, in my opinion, would be to implement the FreeBSD-style behavior by defining GNU_STANDARD=0 in the CFLAGS for the gzip ebuild.

It would also be acceptable to implement this via a USE flag (gnustandard, for example) that would allow the gzcat symlink and "non-GNU-standard" behavior to be restored if -gnustandard was given.
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-05-05 15:49:31 UTC

*** This bug has been marked as a duplicate of bug 175279 ***