[LFS Trac] #2344: Tar Revert Pipe Drain Patch

LFS Trac trac at linuxfromscratch.org
Sun Feb 8 06:18:55 PST 2009


#2344: Tar Revert Pipe Drain Patch
----------------------+-----------------------------------------------------
 Reporter:  willimmn  |       Owner:  lfs-book@…                   
     Type:  task      |      Status:  new                          
 Priority:  normal    |   Milestone:  7.0                          
Component:  Book      |     Version:  SVN                          
 Severity:  normal    |    Keywords:                               
----------------------+-----------------------------------------------------
 CLFS is using two other Tar patches that apply for 1.21.

 The first one, tar-1.21-manpage-1.patch, just makes a Tar manpage, and I
 don't think LFS will use it anyday.

 The second one, tar-1.21-revert_pipe_drain-1.patch, is a patch that is
 considered to be in LFS. Why? As a example with unpatched Tar 1.21,
 download this example tarball: (of Glibmm, BTW)

 ftp://ftp.gnome.org/pub/gnome/sources/glibmm/2.18/glibmm-2.18.1.tar.bz2

 And try to unpack it by running this command:

 bzip2 -dc glibmm-2.18.1.tar.bz2 | tar xof -

 Tar runs with no error, however, run strace and you will get this output:

 {{{
 write(1, "glibmm-2.18.1/\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 4096)
 = -1
 EPIPE (Broken pipe)
 --- SIGPIPE (Broken pipe) @ 0 (0) ---
 +++ killed by SIGPIPE +++
 }}}

 Look at this output closly and you will see that bzip2 acualy died because
 of a broken pipe. Now you see why this patch is a good idea for LFS? It is
 attached with this ticket.

-- 
Ticket URL: <http://wiki.linuxfromscratch.org/lfs/ticket/2344>
LFS Trac <http://wiki.linuxfromscratch.org/lfs/>
Linux From Scratch: Your Distro, Your Rules.



More information about the lfs-book mailing list