[HLUG] Source RPMs

Mark Broadbent mgjbroadbent at googlemail.com
Tue Jan 16 09:33:31 GMT 2007


On 15/01/07, Jeff Tupholme <jeff at repositive.com> wrote:
> Hi all,
>
> I believe most people are running Ubuntu but I still have a couple of
> machines running a Red Hat variant (Yellow Dog).

Some of us still run Redhat based systems ;-)

> That uses RPM for
> its package management. I want to add a couple of additional codecs
> to ffmpeg that are only available in source form, so I thought I
> would try to incorporate them into the source RPM (SRPM). I believe I
> can unpack the SRPM and add the extra directories in before building;
> the ffmpeg Makefile is supposed to notice them and roll them in.

To unpack a SRPM simply install it as you would with a binary
packages, the contents are then placed in the /usr/src/redhat
directory (the directory might not be called redhat in your case).
The .spec file for the package is in SPEC/, the source package is in
SOURCES/, for what you want to do you could either:

* Unpack the ffpmeg tar file, add the extra directories, tar the
ffmpeg source and place back into the SOURCES directory and rebuild
the package.
* The more complicated but preferred option would be to generate a
patch files that, when applied to the ffmpeg tree, adds all the new
files and directories.  The patch file can then be listed in the .spec
file and will be applied at build time.  The reason that this is a
better way is because in the future you can update the ffmpeg source
distribution independently of the patch file.

> Sounds easy, but anyone who has done this sort of thing before have
> any tips before I start!?

It's not that difficult once you have done it a few times, it's just
learning where everything is kept!

Good luck!
Mark

-- 
Mark Broadbent
* http://www.wetlettuce.com/



More information about the Herefordshire mailing list