Have a look at tarrubyscript.rb in tar2rubyscript.tar.gz [1].
It might be a good start. Although I'm not sure it can
handle every kind of TAR file...

By the way, that code was written by from Thomas Hurst, long
time ago...

Oh, it's not a library; it's code.

gegroet,
Erik V. - http://www.erikveen.dds.nl/

 [1] http://www.erikveen.dds.nl/tar2rubyscript/index.html