[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: how to rebuild from src.rpm while patching the Makefile



On Wed, 26 Mar 2003, Robert P. J. Day wrote:

  it's been a while since i've had to mess with the internals of
a src.rpm, so i just want to clarify how to do this the approved way.

i want to install the NVIDIA kernel src rpm, then do the normal
"prep" step, *then* apply some patches to the makefile, *then* complete the build process, so that the NVIDIA modules will work
with the 2.5 kernel.


as i see it, i should

1) do a normal install of the src rpm
2) wander into /usr/src/redhat/SPECS and do a

# rpmbuild -bp NVIDIA.spec

3) apply my patches in the apropriate source directory

... and then ... is there a single rpmbuild command to resume the build from there? or do i do an explicit "make"
to finish things off?


recommendations appreciated.

Well, it is considered bad practice to fiddle with the source-tree half-way a build ;) You should either create patches (as Matthias demonstrated) or add one-liners to the %setup (or if really necessary) to the %build stage.


I often do something like:

perl -pi -e 's|/usr/local|\$(prefix)|g' Makefile

or something and report this upstream. (It is more transparant sometimes do to it like that than to use a patch that does the same).

Kind regards,
--   dag wieers,  dag@wieers.com,  http://dag.wieers.com/   --
«Any errors in spelling, tact or fact are transmission errors»





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []