P7zip

p7zip is [[Article description::a command-line port of 7-Zip for POSIX compliant systems such as Unix, OS X, BeOS, and Amiga.]] Created by Igor Pavlov, the 7-Zip compression type implements the LZMA compression algorithm, which is one of the highest compression ratios currently available. Since version 4.10 it supports little and big endian machines.

Emerge
p7zip can be installed by running:

Invocation
There are three different ways to invoke the compression utility:



If compiled with the USE flag it also provides a graphical interface via the following invocations:



Also a wrapper included is for :



Extraction of files to current directory
To extract all files from an archive to the current directory without using directory names, use the following command:

Where  is to be replaced with the archive's name.

To extract with full paths, use the following command:

Extraction to a new directory
To extract into a new directory, use the following command:

Where  is the name of the new folder.

Preserving file attributes
When using 7-zip on Gentoo or any other operating system that should preserve Unix file permissions, tar will need to be used in conjunction with 7z to archive or extract files.

Use the following command to archive directories of files, preserving Unix file permissions:

To extract: