LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   Compilation error with 5.2.14 (https://www.linuxquestions.org/questions/linux-kernel-70/compilation-error-with-5-2-14-a-4175660781/)

Arden97 09-12-2019 05:52 AM

Compilation error with 5.2.14
 
Good day!

Recently, I got an interest in the Linux kernel, so I took the latest stable version (5.2.14) from kernel.org and tried to compile it with the default configuration. After running
Code:

make mrproper && make defconfig && make
i get an error:
Code:

/bin/sh: kernels/linux-5.2.14: No such file or directory
make: *** [Makefile:1726: tools/objtool] Error 127

I use Arch Linux and I have all the necessary tools described on archwiki installed.
Can someone help me? What am i doing wrong?

business_kid 09-13-2019 08:04 AM

It looks like you haven't started in a full linux kernel install. Here's what the top source directory should look like
Code:

bash-5.0$ ls /usr/src/linux-4.19.59
COPYING        Kbuild        MAINTAINERS  arch  config-4.19.59  firmware  init    lib  samples  sound  virt
CREDITS        Kconfig        Makefile    block  crypto            fs        ipc    mm  scripts  tools
Documentation  LICENSES  README      certs  drivers            include  kernel  net  security  usr
bash-5.0$ du -sh
916M        .

There's been a kernel made in that, so it's bigger than usual. But it's a several hundred megs, and they never get smaller. cd to /usr/src/linuv-5.2.14, and try there.

Arden97 09-14-2019 07:14 AM

Quote:

Originally Posted by business_kid (Post 6036389)
It looks like you haven't started in a full linux kernel install. Here's what the top source directory should look like
Code:

bash-5.0$ ls /usr/src/linux-4.19.59
COPYING        Kbuild        MAINTAINERS  arch  config-4.19.59  firmware  init    lib  samples  sound  virt
CREDITS        Kconfig        Makefile    block  crypto            fs        ipc    mm  scripts  tools
Documentation  LICENSES  README      certs  drivers            include  kernel  net  security  usr
bash-5.0$ du -sh
916M        .

There's been a kernel made in that, so it's bigger than usual. But it's a several hundred megs, and they never get smaller. cd to /usr/src/linuv-5.2.14, and try there.

That helped. I wonder, why than the majority of tutorials on the Internet describe the kernel compilation in the home directory?


All times are GMT -5. The time now is 02:25 AM.