Hi,
I (with DaveJ) help maintain the kernel release notes for Fedora. A user suggested a while back that we remove the building instructions from the release notes and put those in a separate doc devoted to more detailed instructions on building the kernel RPM (including applying patches and configuring options).
I've got a draft doc now. I come to this from a support perspective - building kernels with patches I get from Engineering to pass on for testing. I'd like to get the point of view of some kernel developers as well.
- Is what's here correct? - Is there more that should be here? - Does the info here conform to best practices?
Any feedback appreciated. I am happy to make edits myself if you reply, or of course any one can make edits on their own.
http://fedoraproject.org/wiki/Docs/Drafts/CustomKernel
Thanks, Sam
Sam Folk-Williams wrote:
Hi,
I (with DaveJ) help maintain the kernel release notes for Fedora. A user suggested a while back that we remove the building instructions from the release notes and put those in a separate doc devoted to more detailed instructions on building the kernel RPM (including applying patches and configuring options).
I've got a draft doc now. I come to this from a support perspective - building kernels with patches I get from Engineering to pass on for testing. I'd like to get the point of view of some kernel developers as well.
- Is what's here correct?
- Is there more that should be here?
- Does the info here conform to best practices?
Any feedback appreciated. I am happy to make edits myself if you reply, or of course any one can make edits on their own.
When copying the kernel tree, the second copy should be:
cp -alv ~/rpmbuild/redhat/kernel-2.6.x.orig ~/rpmbuild/redhat/kernel-2.6.x.new
this will hardlink the original and new trees so diff will run much faster. Hardlinks should not present a problem because text editors know how to break them -- Midnight Commander now asks, so maybe a note telling people about the hardlinks could be added there as well.
On 04/02/07 11:29 -0400 Chuck Ebbert wrote: <snip>
When copying the kernel tree, the second copy should be:
cp -alv ~/rpmbuild/redhat/kernel-2.6.x.orig ~/rpmbuild/redhat/kernel-2.6.x.new
this will hardlink the original and new trees so diff will run much faster. Hardlinks should not present a problem because text editors know how to break them -- Midnight Commander now asks, so maybe a note telling people about the hardlinks could be added there as well.
Thanks Chuck - made that change.
Anything else - just let me know.
-Sam
On Thu, 29 Mar 2007 09:24:07 -0400, Sam Folk-Williams samfw@redhat.com wrote:
Any feedback appreciated. I am happy to make edits myself if you reply, or of course any one can make edits on their own. http://fedoraproject.org/wiki/Docs/Drafts/CustomKernel
I'm not quite sure that I have the last word here, so I'll just reply
* rpm-build * rpmdevtools * yum-utils * gcc * redhat-rpm-config * ncurses-devel * unifdef
This changes over time and I do not bother remember this. I just run rpmbuild --bp, and it tells what packages it needs. Maybe you want to mention that it's ok to run rpmbuild, see what falls out? For example, it's likely that we'll require sparse just as soon as the Core+Extras merge happens.
The second diff command will hardlink the orig and new trees so that the diff will run faster. Text editors should know how to break the hardlink, so this should not present a problem.
I see you applied Chuck's suggestion. I would mention also that vi specifically is the most notable exception. You have to break links before editing with vi.
-- Pete
On 04/05/07 17:05 -0700 Pete Zaitcev wrote:
On Thu, 29 Mar 2007 09:24:07 -0400, Sam Folk-Williams samfw@redhat.com wrote:
Any feedback appreciated. I am happy to make edits myself if you reply, or of course any one can make edits on their own. http://fedoraproject.org/wiki/Docs/Drafts/CustomKernel
I'm not quite sure that I have the last word here, so I'll just reply
* rpm-build * rpmdevtools * yum-utils * gcc * redhat-rpm-config * ncurses-devel * unifdef
This changes over time and I do not bother remember this. I just run rpmbuild --bp, and it tells what packages it needs. Maybe you want to mention that it's ok to run rpmbuild, see what falls out? For example, it's likely that we'll require sparse just as soon as the Core+Extras merge happens.
Thanks Pete - I had been trying to keep a comprehensive list, but if it changes frequently there's really no point. Applied your recommendation.
The second diff command will hardlink the orig and new trees so that the diff will run faster. Text editors should know how to break the hardlink, so this should not present a problem.
I see you applied Chuck's suggestion. I would mention also that vi specifically is the most notable exception. You have to break links before editing with vi.
Noted.
Thanks, Sam
-- Pete
On Thu, 2007-03-29 at 09:24 -0400, Sam Folk-Williams wrote:
I (with DaveJ) help maintain the kernel release notes for Fedora. A user suggested a while back that we remove the building instructions from the release notes and put those in a separate doc devoted to more detailed instructions on building the kernel RPM (including applying patches and configuring options).
I'm surprised that you advocate downloading the src.rpm and building from that. I would recommend checking the kernel package out from CVS instead. It's easier to see what you've changed ('cvs diff'), and much easier and quicker to update to later kernels when the Fedora folks ship an erratum and you want to update your own version to be based on it.
I'd also like to see the document cover building _modules_. For example, I have this patch to bcm43xx and how do I make a module to test it? I certainly don't rebuild the whole damn kernel -- I run 'make prep' in the CVS directory, then apply the patch manually (or hack on the code as appropriate), and build it with: make -C /lib/modules/`uname -r`/build SUBDIRS=drivers/net/wireless/bcm43xx modules
On Mon, 2007-04-16 at 13:29 +0100, David Woodhouse wrote:
On Thu, 2007-03-29 at 09:24 -0400, Sam Folk-Williams wrote:
I (with DaveJ) help maintain the kernel release notes for Fedora. A user suggested a while back that we remove the building instructions from the release notes and put those in a separate doc devoted to more detailed instructions on building the kernel RPM (including applying patches and configuring options).
I'm surprised that you advocate downloading the src.rpm and building from that. I would recommend checking the kernel package out from CVS instead. It's easier to see what you've changed ('cvs diff'), and much easier and quicker to update to later kernels when the Fedora folks ship an erratum and you want to update your own version to be based on it.
I hadn't thought of this. The src RPM method has been recommended for a long time. I think it would be good to add an additional section on using CVS as an alternative. I'll work on that.
I'd also like to see the document cover building _modules_. For example, I have this patch to bcm43xx and how do I make a module to test it? I certainly don't rebuild the whole damn kernel -- I run 'make prep' in the CVS directory, then apply the patch manually (or hack on the code as appropriate), and build it with: make -C /lib/modules/`uname -r`/build SUBDIRS=drivers/net/wireless/bcm43xx modules
Good point. I added a bit about building kernel modules for the currently running kernel (requiring the kernel-devel package). I will also include this in the new CVS info.
Thanks, Sam
kernel@lists.fedoraproject.org