Quote:
Originally Posted by derchris
In general tutorials, it is told to do a make after you configured everything.
In Ubuntu you should use make-kpkg. So what is the difference between those two, why should I use the 2nd one?
|
They encourage you to create a package that the package-manager can track.
https://help.ubuntu.com/community/Kernel/Compile
Quote:
Originally Posted by derchris
My Problem is that I work on kernel module and I don't know whether make-kpkg will recompile the whole kernel even if I just change 1 or 2 files.
|
This depends on whether you ever issue a make-kpkg clean.
Quote:
Originally Posted by derchris
Edit: I just finished compiling. And after about an hour or so, the final message was this:
Code:
dpkg-gencontrol: error: package linux-image-2.6.37.3meinsmeins not in control info
|
Where did you get the source?
If you got them straight from kernel.org, then your source does not include necessary control files, so you must build them.
You really should either be using the a natty source package:
http://archive.ubuntu.com/ubuntu/poo...38-6.34.tar.gz
Or if you plan on making a habit of building your own kernels use git:
Code:
git clone git://kernel.ubuntu.com/ubuntu/ubuntu-natty.git
https://wiki.ubuntu.com/Kernel/Dev/KernelGitGuide
Inside your /home directory:
Code:
mkdir natty
cd natty
git clone git://kernel.ubuntu.com/ubuntu/ubuntu-natty.git
then clone that clean source directory to another to build in
Code:
git clone ubuntu-natty ubuntu-natty-build
then you can
Code:
cd ubuntu-natty-build
and copy a .config file there and do whatever you want to do.
When you are ready to build the kernel then
Code:
fakeroot make-kpkg --initrd --revision=1 kernel_image kernel_headers
to update the sources you can
Code:
cd natty
rm -rf ubuntu-natty-build
cd ubuntu-natty
git fetch
git reset --hard origin/master-next
cd ..
git clone ubuntu-natty ubuntu-natty-build
cd ubuntu-natty-build
and build again
This process enables you to keep a clean source tree.