Rework the sign-extension to avoid left-shift of
an explicit negative number (which newer GCC complains about).
Use ustar format in the test_option_b test

.. because the ustar archive does not store SELinux context.  As the default
format for bsdtar is "restricted pax" (trying to store xattrs and other
things by default), the test failed on Fedora because our files have by
default SELinux context set.  This results in additional data in tested
archive ~> and the test failed because the archive was unexpectedly big:

 tar/test/test_option_b.c:41: File archive1.tar has size 3072, expected 2048

Reviewed by Konrad Kleine <konrad.wilhelm.kleine@gmail.com>
Add more files autogenerated by automake build system to .gitignore.
http://code.google.com/p/libarchive/issues/detail?id=325

Simplify the method/level checks here and fix a bug.
http://code.google.com/p/libarchive/issues/detail?id=325

Close the file handle on error.