rpmrebuild's use
basic use
no need of rpm building knowledge
just rebuild an rpm package from an installed package
you do not find the rpm file ?
just type
rpmrebuild package_name
advanced use
you need to have basic knowledge on rpm spec file syntax ( read the RPM-HOWTO, or go to
rpm.org)
changes in a file
you have changed a configuration file to match your needs, and want to distribute your changes ?
yo will use the same command :
rpmrebuild package_name
, because rpmrebuild build
the package from the installed files.
add a file
want to add a file to a package ?
Put the file on the wanted directory.
you will use
rpmrebuild -e package_name
. rpmrebuild will open the specfile in your favorite editor and
allow you to add the wanted file in the "%files" section.
advices
- rpmrebuild do not need explicitly to be run on root superuser, but you have to be root if some files are root-protected (unix perms 0600)
- the specfile is deleted after use. If you want to keep it, use -s option
- the rpm files are build on "natural" location (for example, on Redhat/Centos/fedora, on /usr/src/redhat/RPMS, by default).
but you may change this with -d option or with ~/.rpmmacros file (add "%_topdir your_dir")
- rpmrebuild has numerous options, check them with man rpmrebuild or rpmrebuild --help
more documentation
you can have a look at rpmrebuild
man page (EXAMPLES section)
back to main page