Custom-Compiling Apache and Subversion
Subject:   Minor tip for systems without a gzip-aware tar
Date:   2005-07-17 23:39:13
From:   aristotle
Instead of gunzipping the file on disk, decompress it to stdout and pipe the result into tar. That means instead of tar xvzf foo.tar.gz you say gzip -cd foo.tar.gz | tar xvf -. This can usually be abbreviated by using the zcat synonym for gzip -cd where it is present (most systems), yielding zcat foo.tar.gz | tar xvf -.

Doing it this way avoids unnecessary roundtrips to the disk, and also having to recompress the whole shebang, which means it’s much faster.