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

Re: compiling (or rather, failing to compile) a kernel



On Sat, Nov 10, 2012 at 2:15 PM, Lisi Reisz <lisi.reisz@gmail.com> wrote:
> On Saturday 10 November 2012 18:46:09 Martin Steigerwald wrote:
>> Am Samstag, 10. November 2012 schrieb Lisi Reisz:
>>>
>>> I have been trying to get to grips with compiling a custom kernel. I
>>> have been shying away for too long.
>>>
>>> I am following Stephen's marvellous work, and had got this far:
>>>
>>> http://users.wowway.com/~zlinuxman/Kernel.htm#Unpack
>>
>> This appears to be really old.
>>
>> I suggest looking at
>>
>> http://kernel-handbook.alioth.debian.org/
>>
>> and "make-kpkg" from "kernel-package". These are the two approaches I know
>> of. I still use make-kpkg, cause it does everything for me in just one
>> command.
>>
>>> But I get errors the end of which is below. I tried to copy and paste
>>> all the error reports that Konsole gave me, but could not manage it.
>>
>>> <quote>
>>> tar: linux-source-3.2/sound/firewire/Makefile: Cannot open: No such
>>> file or directory
>>
>>> lisi@Titan:/usr/src$
>>> </quote>
>>
>> Turned out to be a permissions problem.
>>
>> So you used your regular user to compile the kernel.
>>
>> But a deprecated place for it. Just compile the kernel from a directory in
>> your home directory.
>
> Thanks, Martin. Yes, I have looked at the website you refer to, and tried to
> use it. And I have the book to which you refer. The trouble is, that for
> the basic stuff they are simply above my head. Stephen gives more
> explanation and more and clearer instructions.
>
> I shall certainly avail myself of what the book and
> http://kernel-handbook.alioth.debian.org/ say - but shall also use Stephen's
> site, which I find very useful. So much of the documentation from which one
> has to work is old - but that doesn't make it useless. And anyway, I think
> that Stephen updates his site, so it is not outdated.

Stephen's page isn't outdated. Perhaps kernel-package has been
deprecated by the kernel maintainers [1] [2] - even though it's still
being patched according to the wheezy changelog.

I've also never seen any Debian documentation pointing to building a
kernel elsewhere than in "/usr/src/". It's been the RHEL/Fedora way
for years though.

I don't see what's difficult about [3]. The problem's that if you
follow that exact procedure, you'll end end with the same kernel
version and .deb name as the linux-image package in the official
archive. You can change the kernel version by setting it as
"EXTRAVERSION" at the top of "/usr/src/linux-source-<ver>/Makefile"
(for example, the upstream release candidates set "EXTRAVERSION=-rcX")
and you can change the .deb name with "KDEB_PKGVERSION=<...> make
deb-pkg".

1. http://lists.debian.org/debian-kernel/2009/10/msg00613.html

2. http://lists.debian.org/debian-devel/2012/09/msg00330.html

3. http://kernel-handbook.alioth.debian.org/ch-common-tasks.html#s-common-building


Reply to: