Product SiteDocumentation Site

Filling the List of Files

The %files section holds a list of all the files that RPM should install from the package. This list should be exhaustive, so that the RPM system knows exactly what your package installs. There are some options, though, to name all the files within a directory to help with packages containing hundreds of files.
In the default case, each line under the %files section names a separate file with its full path. For example:
%files
/usr/X11R6/bin/xtoolwait
/usr/X11R6/man/man1/xtoolwait.1
This example lists two files, /usr/X11R6/bin/xtoolwait and /usr/X11R6/man/man1/xtoolwait.1, presumably an online manual files.

Using wildcards

In addition to naming each file on a line, you can use glob-style wildcards. For example:
%files
/usr/X11R6/bin/xtoolwait
/usr/X11R6/man/man1/xtoolwait.*
This example states that all files in /usr/X11R6/man/man1 that start with xtoolwait. should be included in the package.