I’m going to do a few articles on building RPM’s as much for my own reference as anyone elses. I’m not an expert on the subject by any means… I do this from time to time, rebuild an rpm for an older system (or even a newer system that doesn’t have an official rpm for.) I have a tendency to forget things that I don’t do frequently. The first part of being able to rebuild rpm’s is to have what’s called a build environment. For starters, I’m using Mandriva 2006 (older versions I used Mandrake 10.1 or 10.0, etc.) In your home directory you need a folder called rpm.
In that folder you need subdirectories called:
the RPMS folder needs to have subfolders as well:
At this point you just need to have 2 configuration files in your home directory:
.rpmrc which should have the following:
buildarchtranslate: i386: i586
buildarchtranslate: i486: i586
buildarchtranslate: i586: i586
buildarchtranslate: i686: i586
and .rpmmacros which should contain this:
%distribution Mandriva Linux
Make sure to adjust the path correctly. A Mandriva user even has a quite script to do all the above for you… it’s here setup4rpm.sh Once this is done you’ve got all the folders you need.
The only other bit of advice I can give on the environment for rpm building. IF the packages are intended for others, try to keep the system as close to an “official” mandriva system as possible, try not to have requirements that would have users hunting for obscure non-mandriva packages. Ideally packages for public consumption with Mandriva should just have Main/contrib/updates requirements (maybe plf depending on what it is I suppose….) For your own use though, it’s up to you how “clean” your build system is.
Related PostsRelated 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......
- Firefox 220.127.116.11 RPMS for Mandriva 2006 Just an update to let you know I've recompiled the src rpm's from Cooker for Mozilla 18.104.22.168 (For Mandriva 2006) and am uploading them to a subdirectory in http://www.averyjparker.com/wp-content/downloads/firefox/. (Look for the Mozilla-Firefox-22.214.171.124 subdirectory... thought it would be fairly obvious.) Anyway, I've put the src rpm in a subdirectory mysteriously......
- Recovering a Split BiggieFile from a MondoRescue Backup Once upon a time I wrote of manually extracting a file from a mondorescue backup. Sometimes it's just easier to do that, than have mondorescue go through 30 some cds or dvds just to find one file. (Not to mention the fact that the iso's aren't burned to disc but......
- Listing Building 101 - How To Build A Huge List To understand the art of list building you first have to know the audience you are marketing too.Â This is the key to getting people to opt in to your autoresponder. A huge mistake that many people do is they lead with a business opportunity on the front end of......
- Green Building Recap 10.14.10 Here's a bit of green building news I found surfing around this week - some news, some building info. Follow me on Twitter and Facebook for daily newsfeeds! > Before Dow Chemical came along about 1920, many things, from Levi jeans to buildings, were made of hemp. We are not......
- 2 Ways to Learn Acoustic Guitar When people are first learning to play the guitar, the acoustic type is generally recommended over the electric type. The main reason for this is that the strings of an acoustic guitar are tougher, so they build calluses better, and help build finger strength. As for the methods by which......
- Building RPM’s from Source RPMs
- Building RPM’s – building from tarballs
- Mozilla Firefox 1.5 for Mandriva 2006
- Building RPM’s – building for several different releases on one machine
- Firefox 126.96.36.199 RPMS for Mandriva 2006