Re: RedHat equivalent of make-kpkg?
Tzafrir Cohen <[EMAIL PROTECTED]> writes: > No, they are not. There are built from the big kernel .src.rpm . It > contains houndreds of patches (ok: something between 100 to 200) and > builds with a number of different configurations and CPUs. Nothing here says the provided make target could not be used, though. Factually, it isn't. > Actually: they do none of the above explicitly, IIRC. What they do is > run: > > /sbin/installkernel Fine, that's where the smarts are. Point is, there are extra post-install smarts on top of what the vanilla Makefile provides. -- Oleg Goldshmidt | [EMAIL PROTECTED] = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wed, Dec 03, 2003 at 06:15:04PM +0200, Oleg Goldshmidt wrote: > [EMAIL PROTECTED] writes: > > > So what's the bottom line of all this? That "make rpm" in the vanilla > > kernels is not useful enough? > > I must admit I never used it. I wonder if the RedHat kernels are built > with it. No, they are not. There are built from the big kernel .src.rpm . It contains houndreds of patches (ok: something between 100 to 200) and builds with a number of different configurations and CPUs. "Use it if you feel like buiding your kernel around 10 times for each change." > I gave scripts/mkspec a quick look, and it looks like RH are > a bit smarter, in the sense that they > > * add a stanza to /etc/lilo.conf > * run lilo > * make initrd with the new kernel > > All of the above carries no warranty - I cannot be sure I am not > missing something. Actually: they do none of the above explicitly, IIRC. What they do is run: /sbin/installkernel Which should do whatever is necessary for that specific distro. Note that all distro kernels tend to use initrd. This is often unnecessary with a custom kernel and removing it can reduce the startup-time and complexity of the system. But make sure your system can boot. -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wed, Dec 03, 2003 at 08:02:10PM +0200, Diego Iastrubni wrote: > Tzafrir Cohen wrote: > >echo "%define __debug_install_post #" > >echo "%define debug_package #" > > > >After getting the following error: > > > >error: Could not open %files file > >/home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or > >directory > > Could not open %files file > > /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or > > directory > > > >But I figure that there must be a better way. > > > > > > > you can do what I do most of the time, it's an ugly hack but it does work > %files > / > > i know what it does, not lecture me about whats good or not in this. I > know this already. As I said it's an ugly hack. The problem is not the list of %files. It's already there and works. The problem is that rpm tries to create a -debug package (a packge with debug symbol files). For some reason it fails. I don't really care why, because I don't need it. A number of other issues: * /lib/modules/$version/build is a link to the build directory , which can be something like /home/tzafrir/RPM/BUILD/$version Not useful after the RPM is transfered to another machine * "release tag": make-kpkg gives you a number of such options. With the above method you're on your own. Something to remember: Suppose you built a package with version number "2.4.22" and installed it. Later on (after the reboot) you decide you want to build the kernel with a different onfiguration and rebuild the package with a different config. The modules will be installed to the same place. If the original kernel will try to load a module it will load a module of the new kernel. If the configuration differs enough this could be bad. Thus it is probably preffered to reboot a while after upgrading that kernel package. (There's nothing specific to working with kernel packages. But when you work with rpm/deb you tend to have the feling that just installing the package is enough and will fix things) -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
[EMAIL PROTECTED] writes: > So what's the bottom line of all this? That "make rpm" in the vanilla > kernels is not useful enough? I must admit I never used it. I wonder if the RedHat kernels are built with it. I gave scripts/mkspec a quick look, and it looks like RH are a bit smarter, in the sense that they * add a stanza to /etc/lilo.conf * run lilo * make initrd with the new kernel All of the above carries no warranty - I cannot be sure I am not missing something. -- Oleg Goldshmidt | [EMAIL PROTECTED] = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
Tzafrir Cohen wrote: On Wed, Dec 03, 2003 at 08:39:43AM +0200, [EMAIL PROTECTED] wrote: Is there any red-hat equivalent for Debian's make-kpkg? For those who don't know what it is - make-kpkg allows one to take a vanilla kernel source and build .deb files for the kernel image, modules etc. It just looks a bit wierd to me that such an important part of the system like the kernel image should just be cp(1)'ed over to /vmlinux and linked manually, without making the RPM database aware of the change and helping me keep track of the installed kernels on the system. A number of other issues: usually when you install a new kernel that you built you keep the old one for a while. At least until you see it boot. Thus it might be useful to think about installing a number of them side-by-side. Thus there are a number of other tasks involved in a kernel package: 1. update an entry in lilo.conf/grub.conf 2. run lilo, if lilo is used 3. If you need an initrd: create it at compile time or package install time? There are a number of distro-specific scripts to automate those tasks and hide some details that change occasionally. I would have loved to use the source rpm of redhat or Mandrake and to get a kernel package with exactly he same script and maybe modify some patches etc. However that srpm needs serious hacking (with an axe). It is an overly-complex script that builds the kernel around 5 times with 5 different configurations. I have tried this hacking and failed. I also asked the rpm list and nobody admitted to be using it. So 'make rpm' seems like a useful thing to do: untar kernel apply patches make {menu|x|old}config make rpm I don't remember if 'make distclean' and/or 'make dep' are required anywhere. I have a spec that is based on its output with a simple postinst script and a custom .config file. I have added the following to scripts/mkspec to work around a problem with RH9: echo "%define __debug_install_post #" echo "%define debug_package #" After getting the following error: error: Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory But I figure that there must be a better way. you can do what I do most of the time, it's an uglu hack but it does work %files / i know what it does, not lecture me about whats good or not in this. I know this already. As I said it's an ugly hack. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wed, Dec 03, 2003 at 05:42:31PM +0200, [EMAIL PROTECTED] wrote: > Tzafrir Cohen wrote: > >A number of other issues: > > > >usually when you install a new kernel that you built you keep the old > >one for a while. At least until you see it boot. Thus it might be useful > >to think about installing a number of them side-by-side. > > That's another reason why make-kpkg is nice - these days I find myself > compiling 2.6testX kernels twice a week and sometimes multiple times a > day (I try to help people shoot the problems I reported on LKML), and > it's nice to keep track of what's going on through dpkg. Note that unlike debs, building an rpm is running a script and not running a makefile. No easy shortcuts in case of a compilation problem, but the result is more reproducable. [ snip ] > So what's the bottom line of all this? That "make rpm" in the vanilla > kernels is not useful enough? It is. At least if you don't hit anything else. If you hit that error message you are already provided with a workaround. One other thing I forgot to mention: Should be relevant to 2.4 and not to 2.6, as the config system has be rewritten in a sane way (right?): Even after you run 'make xconfig' or 'make menuconfig' run 'make oldconfig' to make sure 'make oldconfig' requires no input. Those three don't seem to be exactly in sync. -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
Tzafrir Cohen wrote: A number of other issues: usually when you install a new kernel that you built you keep the old one for a while. At least until you see it boot. Thus it might be useful to think about installing a number of them side-by-side. That's another reason why make-kpkg is nice - these days I find myself compiling 2.6testX kernels twice a week and sometimes multiple times a day (I try to help people shoot the problems I reported on LKML), and it's nice to keep track of what's going on through dpkg. Thus there are a number of other tasks involved in a kernel package: 1. update an entry in lilo.conf/grub.conf 2. run lilo, if lilo is used 3. If you need an initrd: create it at compile time or package install time? There are a number of distro-specific scripts to automate those tasks and hide some details that change occasionally. Right. For debian it's make-kpkg. I would have loved to use the source rpm of redhat or Mandrake and to get a kernel package with exactly he same script and maybe modify some patches etc. However that srpm needs serious hacking (with an axe). It is an overly-complex script that builds the kernel around 5 times with 5 different configurations. I have tried this hacking and failed. I also asked the rpm list and nobody admitted to be using it. So 'make rpm' seems like a useful thing to do: untar kernel apply patches make {menu|x|old}config make rpm I don't remember if 'make distclean' and/or 'make dep' are required anywhere. I have a spec that is based on its output with a simple postinst script and a custom .config file. I have added the following to scripts/mkspec to work around a problem with RH9: echo "%define __debug_install_post #" echo "%define debug_package #" After getting the following error: error: Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory But I figure that there must be a better way. So what's the bottom line of all this? That "make rpm" in the vanilla kernels is not useful enough? Thanks, --Amos = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wed, Dec 03, 2003 at 08:39:43AM +0200, [EMAIL PROTECTED] wrote: > Is there any red-hat equivalent for Debian's make-kpkg? > > For those who don't know what it is - make-kpkg allows one to take a > vanilla kernel source and build .deb files for the kernel image, > modules etc. > > It just looks a bit wierd to me that such an important part of the > system like the kernel image should just be cp(1)'ed over to /vmlinux > and linked manually, without making the RPM database aware of the > change and helping me keep track of the installed kernels on the system. A number of other issues: usually when you install a new kernel that you built you keep the old one for a while. At least until you see it boot. Thus it might be useful to think about installing a number of them side-by-side. Thus there are a number of other tasks involved in a kernel package: 1. update an entry in lilo.conf/grub.conf 2. run lilo, if lilo is used 3. If you need an initrd: create it at compile time or package install time? There are a number of distro-specific scripts to automate those tasks and hide some details that change occasionally. I would have loved to use the source rpm of redhat or Mandrake and to get a kernel package with exactly he same script and maybe modify some patches etc. However that srpm needs serious hacking (with an axe). It is an overly-complex script that builds the kernel around 5 times with 5 different configurations. I have tried this hacking and failed. I also asked the rpm list and nobody admitted to be using it. So 'make rpm' seems like a useful thing to do: untar kernel apply patches make {menu|x|old}config make rpm I don't remember if 'make distclean' and/or 'make dep' are required anywhere. I have a spec that is based on its output with a simple postinst script and a custom .config file. I have added the following to scripts/mkspec to work around a problem with RH9: echo "%define __debug_install_post #" echo "%define debug_package #" After getting the following error: error: Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory Could not open %files file /home/tzafrir/RPM/BUILD/kernel-2.4.22/debugfiles.list: No such file or directory But I figure that there must be a better way. -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
ביום רביעי 03 דצמבר 2003, 12:50, נכתב על ידי Tzafrir Cohen: > On Wed, Dec 03, 2003 at 12:30:00PM +0200, Oded Arbel wrote: > > ביום רביעי 03 דצמבר 2003, 12:23, נכתב על ידי [EMAIL PROTECTED]: > > > Oded Arbel wrote: > > > > And that being different from your situation where you need a kernel > > > > source tree of the version you want, in what way ? > > > > > > In the way that it would make me dependent on finding a .srpm > > > file for the kernel I want to compile. > > > > Not so. nothing stopping you from pointing the RPM to another source > > tarball then the one it originally contained. > > Have you tried it? yes > successfully? yes. not recently though, and I wouldn't attempt to modify a 2.4 srpm for a 2.6 installation. building a new spec would probably be a better idea if it weren't for the rpm target in the kernel Makefile. -- Oded ::.. Courage is like love; it must have hope for nourishment. -- Napoleon To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wed, Dec 03, 2003 at 12:30:00PM +0200, Oded Arbel wrote: > ביום רביעי 03 דצמבר 2003, 12:23, נכתב על ידי [EMAIL PROTECTED]: > > Oded Arbel wrote: > > > And that being different from your situation where you need a kernel > > > source tree of the version you want, in what way ? > > > > In the way that it would make me dependent on finding a .srpm > > file for the kernel I want to compile. > > Not so. nothing stopping you from pointing the RPM to another source tarball > then the one it originally contained. Have you tried it? successfully? -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
ביום רביעי 03 דצמבר 2003, 12:23, נכתב על ידי [EMAIL PROTECTED]: > Oded Arbel wrote: > > And that being different from your situation where you need a kernel > > source tree of the version you want, in what way ? > > In the way that it would make me dependent on finding a .srpm > file for the kernel I want to compile. Not so. nothing stopping you from pointing the RPM to another source tarball then the one it originally contained. -- Oded ::.. Instructions for life: 18. Judge your success by what you had to give up in order to get it. To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
Oded Arbel <[EMAIL PROTECTED]> writes: > And that being different from your situation where you need a kernel source > tree of the version you want, in what way ? There might not be a kernel-source RPM for the particular kernel tree he wants. Fortunately, as I pointed out, an RPM can be built from any kernel tree that does not remove or otherwise screw up the rpm target supplied by the vanilla kernel. -- Oleg Goldshmidt | [EMAIL PROTECTED] = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
Oded Arbel wrote: And that being different from your situation where you need a kernel source tree of the version you want, in what way ? In the way that it would make me dependent on finding a .srpm file for the kernel I want to compile. But anyway - the point is apparently mute since, as Olge has pointed out, the vanilla source tree already contains the Make target to create RPM's. Cheers, --Amos = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
ביום רביעי 03 דצמבר 2003, 10:51, נכתב על ידי [EMAIL PROTECTED]: > That wouldn't cut it because then I depend on having a kernel > source RPM for the particular version I want. > > Oded Arbel wrote: > > On Wednesday 03 December 2003 08:39, [EMAIL PROTECTED] wrote: > >>Is there any red-hat equivalent for Debian's make-kpkg? > >> > >>For those who don't know what it is - make-kpkg allows one to take a > >>vanilla kernel source and build .deb files for the kernel image, > >>modules etc. > > > > There is really no need for a specialized method of building kernel > > packages. the RPM building procedure is sufficient for that purpose. get > > a kernel source RPM, modify the configuration and rebuild it. And that being different from your situation where you need a kernel source tree of the version you want, in what way ? -- Oded ::.. More Important then to win is to win dirty. -- Fishizm To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
That wouldn't cut it because then I depend on having a kernel source RPM for the particular version I want. Oded Arbel wrote: On Wednesday 03 December 2003 08:39, [EMAIL PROTECTED] wrote: Is there any red-hat equivalent for Debian's make-kpkg? For those who don't know what it is - make-kpkg allows one to take a vanilla kernel source and build .deb files for the kernel image, modules etc. There is really no need for a specialized method of building kernel packages. the RPM building procedure is sufficient for that purpose. get a kernel source RPM, modify the configuration and rebuild it. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
Oops. Wasn't aware of that. I see it now. Will try it. Thanks. Oleg Goldshmidt wrote: Maybe I don't parse the question right: Looking at the Makefile of a vanilla 2.4.20 kernel I have lying around I see a target to build an rpm. Have you tried it? = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
[EMAIL PROTECTED] writes: > Is there any red-hat equivalent for Debian's make-kpkg? > > For those who don't know what it is - make-kpkg allows one to take a > vanilla kernel source and build .deb files for the kernel image, > modules etc. > > It just looks a bit wierd to me that such an important part of the > system like the kernel image should just be cp(1)'ed over to /vmlinux > and linked manually, without making the RPM database aware of the > change and helping me keep track of the installed kernels on the system. Maybe I don't parse the question right: Looking at the Makefile of a vanilla 2.4.20 kernel I have lying around I see a target to build an rpm. Have you tried it? -- Oleg Goldshmidt | [EMAIL PROTECTED] = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: RedHat equivalent of make-kpkg?
On Wednesday 03 December 2003 08:39, [EMAIL PROTECTED] wrote: > Is there any red-hat equivalent for Debian's make-kpkg? > > For those who don't know what it is - make-kpkg allows one to take a > vanilla kernel source and build .deb files for the kernel image, > modules etc. There is really no need for a specialized method of building kernel packages. the RPM building procedure is sufficient for that purpose. get a kernel source RPM, modify the configuration and rebuild it. -- Oded = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
RedHat equivalent of make-kpkg?
Is there any red-hat equivalent for Debian's make-kpkg? For those who don't know what it is - make-kpkg allows one to take a vanilla kernel source and build .deb files for the kernel image, modules etc. It just looks a bit wierd to me that such an important part of the system like the kernel image should just be cp(1)'ed over to /vmlinux and linked manually, without making the RPM database aware of the change and helping me keep track of the installed kernels on the system. Thanks, --Amos = To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]