# kernel compile error - please Help!

## Oniryczny

Hello,

I wanted to use qemu to compile from my amd64 to arm

so there were few changes in kernel to be made

as usual I did

```

# genkernel --menuconfig all
```

and checked what's needed

but I got errors so I rebooted the system

but it doesn't boot anymore   :Sad: 

I booted from install-minimal media

chrooted and did genkernel --clean --no-oldconfig all

to try generating somewhat default kernet just to boot my machine properly (C2D on P5Q-E, 4096MB DDR2 800MHz and nV 9500GT)

but all I got were errors and a log: http://nopaste.info/89694c8af8.html

--mrproper didn't help as well

----------

## Tractor Girl

Maybe you should try to compile kernel manually, and use genkernel only for initramfs (if you really need it). To be sure you can do it on freshly emerged sources.

```
make && make modules_install

genkernel --install initramfs
```

Do you have old kernel and initramfs?Last edited by Tractor Girl on Sat Jun 28, 2014 5:43 pm; edited 1 time in total

----------

## Oniryczny

that's my stupid mistake... I don't have any backup   :Sad: 

I was always using genkernel with option all

and it always works... well worked til that issue.

At home I use gentoo too and genkernel never surprised me it always compiled all needed things

kernel, modules, and initrd.

I also tried doing it on kernel 3.12.21-r1 anmd happens the same.

----------

## Tractor Girl

Do you use system encryption, have /usr on separate partition or other things like that?

----------

## Oniryczny

nope

I have everything on my /dev/sda1

the only things is swap on /dev/sda2   :Wink: 

I never had any troubles with compilling kernel on my system at work it always used to be easy   :Sad: 

nce I had some problem but I removed files in /etc/kernels and .config in kernel source directory

and it made from default (/usr/share) so I did the same this time

but it didn't solve my problem...

----------

## Tractor Girl

Then you really do not need genkernel at all. Are you using it because you are unfamiliar with kernel configuration? If so, I'm sure people here (including me) can help you.

----------

## Oniryczny

that's right I am a dumbass to compile kernel when I try doing it I always do some mistakes finishing with... kernel panic not syncing   :Razz: 

anyway... why can't I still use it like im doing it at home?

I compilled those qemu options at home and it all works fine on the same kernel (3.10.7)

----------

## Tractor Girl

And what about genkernel versions, are they the same too?

----------

## Oniryczny

sure they are I am updating system about once a week (to make reboot if needed on friday evening)   :Smile: 

----------

## jburns

Looking at your log file the only error I saw was *Quote:*   

> networking/ntpd.c: In function â€ntp_initâ€™:
> 
> networking/ntpd.c:1973:3: warning: format not a string literal and no format arguments [-Wformat-security]
> 
> networking/ntpd.c:2015:3: warning: implicit declaration of function â€setpriorityâ€™ [-Wimplicit-function-declaration]
> ...

 

What does /etc/genkernel.conf contain?

You should check your busybox configuration.

----------

## Oniryczny

never ever chaned it as it was installed and always working...

----------

## Oniryczny

my genkernel.conf is http://nopaste.info/6d66febd7b.html

----------

## jburns

When it builds ntpd it is missing the definition for  PRIO_PROCESS which the kernel defines in /usr/src/linux/include/uapi/linux/resource.h

```
grep PRIO_PROCESS /usr/src/linux/include/uapi/linux/resource.h
```

 should print #define	PRIO_PROCESS	0

A workaround would be to define BUSYBOX="no" in /etc/genkernel.conf

the downside is that if there is a boot error that would allow dropping to a shell there will not be a shell available.

or define 

BUSYBOX_CONFIG="/path/to/file" where "/path/to/file" would point to a file which would be the same as /usr/share/genkernel/defaults/busy-config but with CONFIG_NTPD=n

CONFIG_FEATURE_NTPD_SERVER=n

The downside is that the same error may occur compilling another routine.

----------

## Oniryczny

Thank you, I'll try the advice

anyway, why did it happen if I was using genkernel all the past time?

----------

## jburns

PRIO_PROCESS is defined in /usr/lib64/klibc/include/linux/resource.h which is supplied by the package dev-libs/klibc

It is also defined in /usr/include/linux/resource.h which is supplied by sys-kernel/linux-headers

There is also a definition in /usr/include/bits/resource.h which is supplied by sys-libs/glibc

I would expect that ntpd is using either /usr/lib64/klibc/include/linux/resource.h or /usr/include/linux/resource.h.

You could try re-emerging dev-libs/klibc and sys-kernel/linux-headers to see if that fixes the problem.

----------

## Oniryczny

```

# emerge dev-libs/klibc sys-kernel/linux-headers
```

and then try using genkernel?

only linux-headers is installed in my system so I'm re-emerging it...

```
...

>>> Regenerating /etc/ld.so.cache...

>>> Original instance of package unmerged safely.

>>> sys-kernel/linux-headers-3.13 merged.

>>> Recording sys-kernel/linux-headers in "world" favorites file...

>>> Auto-cleaning packages...

>>> No outdated packages were found on your system.

 * GNU info directory index is up-to-date.

#
```

----------

## Oniryczny

anyway, there's still an error... http://nopaste.info/f86c73ad68.html

----------

## Oniryczny

Still no clues?

----------

