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

Re: how to build a kernel package of flavor 'armmp'



Thank you Ian,
Hit exactly the right spot.

I went with

'write the "-armmp" string (without the quotes this time) to a file
called "localversion" at the root of your kernel source tree.'

and then

'make -j 4 ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- bindeb-pkg'

Although it did not do a total rebuild, I think it rebuilt every
loadable module (kind of expected if they will check kernel
version....).

So, after a further 4 hours compile, and a

'dpkg -i linux-image-4.8.7-armmp_4.8.7-armmp-3_armhf.deb'

I now have on the device:


=====================================
Debian GNU/Linux stretch/sid debian ttyS0

debian login: debian
Password:
Last login: Mon Dec 19 16:27:02 GMT 2016 from 192.168.1.180 on pts/0
Linux debian 4.8.7-armmp #0 SMP Sat Dec 17 20:50:54 GMT 2016 armv7l

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
debian@debian:~$ uname -r
4.8.7-armmp
debian@debian:~$
===================================================

A very happy man :).

I will try to document a little somewhere on a wiki (probably sunxi)
with lots of googleable terms the basic steps I took; it's so good to
be able to have a mainline OS on what I have considered to be a
dead-duck device sitting on my desk (or in my robot, as appropriate).

thanks again,

Simon

On Mon, Dec 19, 2016 at 10:26 AM, Ian Campbell <ijc@debian.org> wrote:
> On Mon, 2016-12-19 at 09:09 +0000, Simon H wrote:
>> However, when using
>> 'dpkg -i linux-image-4.8.7_4.8.7-1_armhf.deb'
>> to install the kernel, the device complains:
>>
>> "Kernel /boot/vmlinuz-4.8.7 does not match any of the expected
>> flavors
>> (armmp), therefore not writing it to flash"
>
> Historically there were several kernel flavours on armhf which would
> only boot on their particular hardware flavour and often a tricky
> recovery procedure (i.e. involve special cables not everyone has etc)
> if you load a bad kernel, so flash-kernel is quite careful/fussy and
> checks the flavour which is part of the "uname" string (i.e. "4.8.7" in
> your case or "3.16.0-4-armmp" for an official kernel image). It's of
> less utility on armmp now that we have consolidated to the single armmp
> flavour, we do still have the -lpae subflavour which needs to be
> avoided on non-capable hardware so the checks aren't completely useless
> on armhf stil.
>
> I'm not sure if there is a way to say "don't worry about the suffix" it
> might be sufficient to edit /etc/flash-kernel/db to add an override
> stanza for your machine:
>     Machine: <contents of your /proc/device-tree/model>
>     Kernel-Flavors:
> i.e. an empty "Kernel-Flavours", or maybe
>     Machine: <contents of your /proc/device-tree/model>
>     Kernel-Flavors: ""
> i.e. with an explicitly empty string.
>
> If neither of those works then the easiest solution IMHO (and what I've
> always done IIRC, it's been a while since I needed to though) is to set
>     CONFIG_LOCALVERSION="-armmp"
> in your kernel .config or, equivalently, to write the "-armmp" string
> (without the quotes this time) to a file called "localversion" at the
> root of your kernel source tree. Rebuilding after such a change
> should(*) only rebuild a handful of files so it should be reasonably
> quick.
>
> HTH,
> Ian.
>
>> p.s. I did do a kernel compile on the device; after 4 days it
>> completed, but i had not packaged it.  So I ran make deb-pkg, and it
>> cleaned my build - bahh!!!
>
> (*) Given this p.s. I'm not so sure of that anymore though :-/
>


Reply to: