RPM-Writing Lab

Posted: January 20, 2011 in SBR600

Today, I will be attempting the RPM-Writing Lab for SBR600.  I used the chess package and GVPE packages as examples in my last post, so  I’m going to continue with the same packages for this RPM build. Lets start with the chess RPM.

Before we do anything, these packages need to be installed:
yum groupinstall “Fedora Packager”
yum install rpmlint yum-utils

Also, Create the ~/rpmbuild directories and the ~/.rpmmacros file:
rpmdev-setuptree

So, I made sure the chess tarball  was in the ~/rpmbuild/SOURCES directory and then i followed that by creating the spec file:
rpmdev-newspec chess

Now that the spec file was made, it was time to edit it. I made a few changes here and there with the little knowledge that I had. When I believed I was done I ran the build command:
rpmbuild -ba nameOfPackage.spec

and sure enough I got a few errors. The first couple of errors were pretty easy to fix and I laughed at myself after i fixed them. This one was a little more difficult to correct:

——————————————————————————————————————-
If the name of the rpm is something other than what the Source unpacks to, use this switch  to specify which directory the tarball unpacks to(Thanks to the fedora How To Package guide):
%setup -q -n chess
After correcting that, the rpmbuild command ran without any errors… Checkmate.
spec file
RPMLINT results:
RPM
SRPM

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s