Bonsai Wiki/ howtos/ building from source rpm

More Information

These instructions are based on the JPackage Rebuilding Instructions.

Initial Setup

Before you can run rpmbuild, you need to setup a directory tree and a .rpmmacros file.

Full directions here

Installing the Source RPM

Make sure to complete the "Initial Setup" section first as the install step uses the .rpmmacros file and rpm tree you created.

Download the source rpm to /tmp.

Install the rpm, you do '''not''' want or need to be root for this command.

rpm -U /tmp/xxx-yyy.src.rpm

The installation should have deposited a spec file in ${HOME}/rpm/SPECS and a bunch of source files in ${HOME}/rpm/SOURCES.

Building the Package

Change directories to the rpm/SPECS subdirectory.

cd ${HOME}/rpm/SPECS

Kick off the build:

rpmbuild -bb packagename.spec

Some packages take quite a while to build.

Harvesting the Binary RPM

When the build completes, the binary rpms are deposited in rpm/RPMS.

ls -lart ${HOME}/rpm/RPMS

Enjoy!

Please let me know if there are issues/problems/confusion with these directions.