rpmrebuild is a tool to build an RPM file from a package that has already been installed

(On debian, the equivalent product is dpkg-repack)


rebuild a lost rpm

It was my first goal : I wanted to a batch rebuild of rpm file from the rpm database, in case of lost files. Command : rpmrebuild package_name

build a modified rpm

You have an installed package, you have customised (configuration ...) and want to distribute this one : just use rpmrebuild to build a new rpm ( no need to know anything about rpm building) ! Command : rpmrebuild package_name

modify the specfile

For advanced users, who know the specfile format, you can edit and modify "on the fly" the specfile with the command : rpmrebuild -e package_name


Plugins allow to make batch changes on specfiles.


any other way

I know there is an "repackage" option in recent rpm releases, but it is not convenient, as you have to uninstall the package ...
(not always possible, because of dependencies)
Eric Gerbier

page changed on 2012-07-10