The information on this page details the process of building an RPM for LSR both by pulling the code from CVS or by using a stable source archive. The instructions are written for the Fedora Core but can be easily modified to work on other distros that support RPMs.
Note that LSR versions 0.2.1 and higher support the building of RPMs. Older versions do not include the required spec file. Also note that we are actively refining the list of LSR dependencies. If an RPM refuses to install or if an RPM installs but LSR refuses to run, please file a Bugzilla bug report.
Also note that the commands for building RPMs directly from a tar file will only work on LSR versions 0.4.0 and higher. The prebuild spec file was not included in previous releases.
Build from stable release
First, download a stable source archive from http://ftp.gnome.org/pub/GNOME/sources/lsr/. The download section on the LSR homepage includes a direct link to the latest stable release. Save it to your home directory.
Now, run rpmbuild on the archive.
cd ~ su rpmbuild -tb lsr-<INSERT VERSION HERE>.tar.gz
The RPM files will be output to the standard RPM build location for your distro or user configuration. The default path on Fedora Core is one of the architecture subfolders in /usr/src/redhat/RPMS. Any RPMs built from a stable release will install by default to /usr/local per the LSB guidelines. The RPM is relocatable, though, so a user can override at install time using the --prefix option to rpm.
Build from Subversion
First, checkout a fresh copy of the lsr module from svn.gnome.org.
cd ~ svn checkout http://svn.gnome.org/svn/lsr/trunk lsr
Next, configure and build the source and a source archive.
cd lsr ./autogen.sh make make distcheck
You can specify a --prefix when executing autogen. If you are building an official RPM for Fedora, the --prefix should be /usr. If you're building a RPM for your own personal repository, the --prefix should be /opt/<YOUR REPO NAME>. See the LSB guidelines for details.
Use the rpmbuild command on the tar file:
rpmbuild -tb lsr-<INSERT VERSION HERE>.tar.gz
The RPM files will be output to the standard RPM build location for your distro or user configuration. The default path on Fedora Core is one of the architecture subfolders in /usr/src/redhat/RPMS. The RPMs will install by default to prefix given to autogen. The RPM is relocatable, though, so a user can override at install time using the --prefix option to rpm.
If you wish to create a second, third, fourth, etc. release of a single version of LSR, you should increment the RPM release number when you build the RPM. For instance, to make a tenth release, do the following:
rpmbuild -tb -D 'custom_release 10' lsr-<INSERT VERSION HERE>.tar.gz