How to update the version of your custom Ubuntu 10.10 kernel

In the article, How to compile a Ubuntu 10.10 (Maverick) kernel the question was asked how to bump the package version after patching the kernel. It isn’t just changing the version number in the changelog. This article will explain how to bump the version number for your custom Ubuntu kernel, it applies to all Ubuntu 10.10 kernel compilation guides I have written.

It is important to remember that you will have to follow this article every time you update your custom kernel. As we will be diverging quite a bit from the Ubuntu git tree, we will be creating a new temporary branch to keep our custom branch in a state so that our custom branch can easily be updated when a new version of the Ubuntu 10.10 kernel is available.

This article assumes you have followed all the steps in the article you followed up to Compilation.
We’ll need to take some extra steps so the compilation process sees our new version number.

We’ll be creating a temporary branch called work.

git checkout -b work

As usual we need to start with the command:

fakeroot debian/rules clean

The Ubuntu kernel maintainers have made it easy on themselves for when a new release is started. This is a good thing for us as well.

DEBFULLNAME="J. Bach" DEBEMAIL="" debian/rules startnewrelease

The DEBFULLNAME and DEBEMAIL are used within the changelog. Set these to your name and email address.

This updates the changelog file and automatically increases the version by 1.
The changelog is located in debian.master/

linux (2.6.35-25.44) UNRELEASED; urgency=low

  CHANGELOG: Do not edit directly. Autogenerated at release.
  CHANGELOG: Use the printchanges target to see the curent changes.
  CHANGELOG: Use the insertchanges target to create the final log.

 -- J. Bach   Mon, 10 Jan 2011 22:00:01 -0500

linux (2.6.35-25.43) maverick-proposed; urgency=low

You can change the version number by hand now if you like, I suggest you keep the same version as the original kernel but add extra information.
For example:

linux (2.6.35-25.43.1) UNRELEASED; urgency=low

We’ll now finalize the changelog by inserting the git commit messages.

debian/rules insertchanges

The changelog now looks like this

linux (2.6.35-25.43.1) UNRELEASED; urgency=low

  [ Upstream Kernel Changes ]

  * sched-automated-per-tty-task-groups
  * Core2 modifications

 -- J. Bach   Mon, 10 Jan 2011 22:00:01 -0500

linux (2.6.35-25.43) maverick-proposed; urgency=low

The entries you see are the git commit messages I used before.

And that’s it, you can now continue at the Compilation section again. To give you a heads up, you must do the command

fakeroot debian/rules clean

as described in the compilation articles.

When you are done with the compilation you can switch to the master branch and delete the temporary branch.

git checkout master
git branch -D work


This article is filed under the categories Ubuntu » Compile a kernel and has the following tags associated with it: , , .

For more of the same articles see the page Compile a kernel for Ubuntu overview