Product SiteDocumentation Site

File Tags

The %files tag lists the files your package should install. For example:
You should mark configuration and documentation files with %config and %doc, respectively. For example:
%config /etc/rc.d/init.d/*
%config /etc/yp.conf
%dir /var/yp
%dir /var/yp/binding

Making relocatable packages

You can make a relocatable package by setting up one or more Prefix tags. For example:
Prefix: /usr
Prefix: /etc
Each file in the %files section must then start with one of the prefixes you provided. With this, installers can easily relocate the package with a command like the following:
# rpm --relocate /etc=/usr/etc file_name.rpm