man page of tar in fedora (and also man page of tar on die.net) mentions the --acls and --xattrs and --selinux options but they are not mentioned in tar manual in GNU website

Why? do this mean fedora package is different from original gnu tar?

3 Answers 3


You can dissect the Fedora source rpm - tar-1.26-29.fc20.src.rpm - and find out.

On Fedora, you can install the src.rpm. You can also extract it's content, like this:

rpm2cpio tar-1.26-29.fc20.src.rpm | cpio --extract --make-directories --verbose

The answer to your question is in tar.spec and the associated patches. Example:

# Add support for extended attributes, SELinux and POSIX ACLs.
# ~> Original implementation #200925
# ~> http://lists.gnu.org/archive/html/bug-tar/2012-08/msg00012.html
# ~> upstream (b997c90f9, 696338043, d36f5a3cc, 085cace18, up-to ~> 83701a590)
Patch10: tar-1.26-xattrs.patch

So yes, Fedora DOES use GNU tar but applies a number of patches - as per src.rpm spec.

  • And you can see that as per Fedora's general policy (n.b. I work on Fedora), those patches were proposed upstream (and it looks like they were committed, too, from the commit ids). So this should all show up in GNU Tar everywhere, eventually.
    – mattdm
    Commented Nov 15, 2014 at 15:46

It is very common for a package maintainer to include distribution specific patches in packages. Sometimes you can find those included in the changelog of the regular package, which you can query with rpm -q --changelog tar

Most often you'll need to check the source package for the details e.g. https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/source/SRPMS/t/tar-1.28-3.fc22.src.rpm which holds the source, spec file and the actual patches that are applied.

Since Red Hat is pushing SELinux much more than other distributions it makes sense that their patches and product documentation also emphasize that.

On mobile no code output


The GNU tar variant you mention has been partly enhanced by code taken from star. This is related to the acl and xattr enhancements that exist since 2001 and 2003 in star.

The SELinux enhancements have been written by RedHat.

Note that these enhancements in GNU tar have not been implemented correctly.

Files may have no ACLs or no SELinux attributes in the archive, but get ACLs or SELinux attributes via heritage when the archive is extracted via GNU tar.

This problem does not exist, when the older original implementation in star is used.

Recent star sources are in the schilytools source package.

If you don't believe this, check the content of an archive with acls, xattrs or SELinux created by GNU tar. You will see that there are SCHILY tags inside, because an archive extension introduced by star was used.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .