GithubHelp home page GithubHelp logo

Comments (3)

kaiwan avatar kaiwan commented on July 30, 2024

Hi @redbilledpanda ,

Thanks for writing..
It's peculiar that you're running into issues with a stable 5.4 kernel.
Could you try simplifying: download a stable kernel source tree from kernel.org (f.e. the latest 5.10 LTS as of now
is 5.10.169; here:
https://mirrors.edge.kernel.org/pub/linux/kernel/v5.x/linux-5.10.169.tar.xz
).

Build it via the usual steps as shown in the book.
Am working on the 2nd edition; here's a simple wrapper script to build the kernel:
https://github.com/PacktPublishing/Linux-Kernel-Programming_2E/blob/main/ch2/kbuild.sh

HTH! Lemme know..

from linux-kernel-programming.

redbilledpanda avatar redbilledpanda commented on July 30, 2024

Hello @kaiwan

IMHO, the kernel build process is so tightly coupled with the underlying build infrastructure that certain things are taken for granted. Problems like the ones I mentioned above arise when we try do go against the established norm, like using a recent build system to compile a relatively older kernel. I am actually a bit aghast at the huge amount of complexity that has gone into the build process itself vis-a-vis getting the configuration just right enough to build and boot. For instance, building the 5.10.169 version of the kernel on my machine gives this error:

make[1]: *** No rule to make target 'debian/canonical-revoked-certs.pem', needed by 'certs/x509_revocation_list'.  Stop.
make[1]: *** Waiting for unfinished jobs....

As this post mentions, I could actually disable the whole key related shebang or else I would have to actually install a certificate that the kernel build process recognizes.

So I went with the second option of installing certfificates, taking help from the above link. After that, I was able to finally boot into this kernel, sigh! By the way, how is it that even with this new kernel, the existing window manager (LXDE in my case) starts without any issue as if nothing happened? Can we say that the window manager startup daemon (it has to be a daemon after all right?) is abstracted from the rootfs layout process? If not how to explain it?

Anyways, thanks for being so responsive and prompt and for writing such a detailed book. After ULK and LKD which are great but way too old now, this will be my go to book. Additionally, it's good to know that a second edition is also on the cards! I hope it'll be coming out soon and be available on Safari (the learning platform).

from linux-kernel-programming.

kaiwan avatar kaiwan commented on July 30, 2024

Hello @kaiwan

IMHO, the kernel build process is so tightly coupled with the underlying build infrastructure that certain things are taken for granted. Problems like the ones I mentioned above arise when we try do go against the established norm, like using a recent build system to compile a relatively older kernel. I am actually a bit aghast at the huge amount of complexity that has gone into the build process itself vis-a-vis getting the configuration just right enough to build and boot.

Hm, yeah... we have to take the good with the bad..

For instance, building the 5.10.169 version of the kernel on my machine gives this error:

make[1]: *** No rule to make target 'debian/canonical-revoked-certs.pem', needed by 'certs/x509_revocation_list'.  Stop.
make[1]: *** Waiting for unfinished jobs....

As this post mentions, I could actually disable the whole key related shebang or else I would have to actually install a certificate that the kernel build process recognizes.

Yes.. my helper script simply disables it...

So I went with the second option of installing certfificates, taking help from the above link. After that, I was able to finally boot into this kernel, sigh!

Nice!

By the way, how is it that even with this new kernel, the existing window manager (LXDE in my case) starts without any issue as if nothing happened? Can we say that the window manager startup daemon (it has to be a daemon after all right?) is abstracted from the rootfs layout process? If not how to explain it?

It's just this- the kernel has very loose coupling with the rootfs; thus, it simply works.. things break when you use a very old rootfs with newer kernels (>=3.x) or vice-versa..

Anyways, thanks for being so responsive and prompt and for writing such a detailed book. After ULK and LKD which are great but way too old now, this will be my go to book.

Thanks you!

Additionally, it's good to know that a second edition is also on the cards! I hope it'll be coming out soon and be available on Safari (the learning platform).
Well, it'll be available on the Packt platform at least...
Thanks for writing in, and the very best with kernel adventures :-)

from linux-kernel-programming.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.