Building RPM’s from Source RPMs



Let me start by saying I am FAR from being an expert on the subject of building rpm’s… RPM’s are binary packages for use in red-hat based distributions. They are used (*in my case on Mandriva) with urpmi to install. Urpmi is a “wrapper” around the rpm utility that figures out what dependencies a program has and then installs those dependencies along with that program. One problem under linux is that binaries are not necessarily portable from one version of a distribution to another. For instance, some of the rpm’s for cooker may not be compatible with an old 10.0 system. But, there are src.rpm’s that can be rebuilt.


That’s what we’ll be looking at here, rebuilding rpm’s from source rpms. Let’s say I find the brand new version of flightgear in cooker (which I did a few days back). Now, I don’t know that the binary rpm will work so I find it’s src rpm (look in the SRPMS directory on the servers). Download that file (say to /home/username/downloads/srpms…)

Assuming you have a good build environment all you need to do at this point is ***AS YOUR USERNAME – NOT AS ROOT*** type the following
$rpm –rebuild /path/to/my/program.src.rpm

If all goes well, you will have lot’s of information stream across the screen (compile process.) NEAR the end (maybe 15 lines up?) You will see a message along the lines of

Wrote: /home/youruserdir/rpm/RPMS/i586/libsimgear0-devel-0.3.9-1.1.20060mdk.i586.rpm

To install all you ought to need to do is urpmi /path/to/my/shinynew/program.rpm (su to install(or sudo urpmi))

If the process didn’t go so smoothly, be sure to READ the errors it gives. Usually the most likely problems are build-requires. In other words, in order to build the package you need to install the following -devel libraries. That’s easily solved (usually), become root and urpmi each of the missing packages. Assuming you’ve got a good list of urpmi sources (main and contrib mirrors from online) you should be in good shape for most of what you’d need to rebuild. The above -devel library was a build-requires for flightgear that wasn’t available to me and so, I had to get THAT src.rpm and build (and install) before rebuilding flightgear.

I’ve noticed too that when I was rebuilding Mandriva 2006 packages on 10.1 I had to make frequent changes to the spec files. A bit more on that will be covered in another post.

Related Posts

Blog Traffic Exchange Related Posts
  • Mozilla Firefox 1.5 for Mandriva 2006 Mandriva 2006 released without Mozilla Firefox 1.5, it came with 1.0.6 (which included security fixes and other patches from 1.0.7).... anyway, source rpm's for Firefox 1.5 became available in cooker, so I've built rpm's for Mandriva 2006 for easy management on my systems. I'll post links here as they may......
  • Remote Tech Support with x11vnc and wrapper script So, the idea is that I wanted something "like" the Ultranvnc Single Click download, only for linux. The main idea being is that if someone is looking for a bit of desktop tech support on linux, we don't need to be giving instructions for 5 different package managers, or source......
  • MPlayer Video Stream Lagging Audio On my (somewhat older) laptop, I've noticed that MPlayer sometimes gets the audio and video out of sync. The audio is moving faster than the video. I've noticed this in octoshape streaming as well as in playing standalone videos. I discovered a quick fix to this is to use the......
Blog Traffic Exchange Related Websites
  • New York Public Sector Can Save Money with High Bay Fixtures President Obama is making good on his campaign promise to invest in renewable and sustainable energy. The American Recovery and Reinvestment Act of 2009 is a solid green initiative that says: we are not just talking the talk, but we are walking the walk.  Millions of dollars have been filtered......
  • Learn How to Build a Wall You may end up with a remodeling project that involves learning how to build a wall in the interior of your home or another similar building. Building a nonbearing interior wall is actually a relatively easy process. If you have basic carpentry skills and a good set of working tools,......
  • Green Home Improvement Tips The green home improvement movement is very strong these days.  It seems that no matter which direction you look, you’ll find some new article being written about it.  Some of the articles are written by people that are very gung-ho about ecologically friendly home improvement.  There is nothing wrong with......
www.pdf24.org    Send article as PDF   

Similar Posts


See what happened this day in history from either BBC Wikipedia
Search:
Keywords:
Amazon Logo

Comments are closed.


Switch to our mobile site