Daniel P. Barron

Category: Eulora Published: August, 29


In my Gentoo Eulora Quest I mentioned how the shitgnomes like to break the recipe on a monthly basis, and right on cue they have done it again; this time in an apparent response to my own publication. I had gone to the trouble of figuring out which is the latest linux kernel that supports the official NVIDIA drivers. At the time, it was version 4.1.35, and that's why my recipe specifically used it. But if you try to emerge sys-kernel/gentoo-sources:4.1.35 today, you'll get an error about how it does't exist. It's even been removed from the official gentoo wiki. It's not that all older kernels have been removed; specifically the one I named has been removed. Needless to say, if you build gentoo with my instructions, it won't work. A simple fix is to change the world file so that it doesn't require an exact version of gentoo-sources, and since I masked the later incomaptible ones, it'll end up pulling version 3.10.107. I tried using this, and although it barfs on my pre-made kernel config, it does seem to result in a working Eulora -- except that when the game closes, the screen goes black and you can only continue using the machine over a network connection. That's alright though, we can still use the proper kernel, and in the proccess learn how to have more control over our cuntoo.

I've put together a file you can download here, containing the necessary components to this fix. It's an RSA clearsigned, base64 encoded, gziped tape archive of the kernel source code and the coresponding gentoo ebuild files.

First, download the files.

naomi ~ # curl "http://danielpbarron.com/2017/shitgnomes/4.1.35.asc" > 4.1.35.asc

Verify my signature.

naomi ~ # gpg --verify 4.1.35.asc 
gpg: Signature made Tue 29 Aug 2017 11:54:01 AM EDT using RSA key ID 9D961AC9
gpg: Good signature from "Daniel P. Barron (danielpbarron)"
gpg: WARNING: This key is not certified with a trusted signature!
gpg:          There is no indication that the signature belongs to the owner.
Primary key fingerprint: 1559 34BD D16E 8EAF 4493  CB9C B36A E984 9D96 1AC9

If gpg isn't installed yet, get it. Make sure the crapolade mask file is already in place. Or else, check the signature on your designated RSA-tron and copy it over afterwards.

naomi ~ # grep gnupg /etc/portage/package.mask/crapolade 
naomi ~ # emerge --ask app-crypt/gnupg

Install sharutils which contains uudecode needed to decode the tarball. Or you can do this step on another machine and copy it over. Not that this is a bad package to have.

naomi ~ # emerge --ask app-arch/sharutils

Decode it. This line will chop the encoded file out of the RSA sig stuff. Apparently it's smart enough to find the encoded file and ignore the trailing and leading RSA sig stuff.

naomi ~ # head -n 1846122 4.1.35.asc | tail -n 1846113 | uudecode
naomi ~ # uudecode 4.1.35.asc

Check that the sha512sum is correct.

naomi ~ # grep $(sha512sum 4.1.35.tar.gz) 4.1.35.asc 
4.1.35.asc:3f3960c978beddb49cc4cef69678395765485103f0db2ea547c86abab35c1b6029d7e78fb7c8ce397f08b3c6dc40bf180df500607d9c49479a6bd31b55beb45f  4.1.35.tar.gz

Untar it.

naomi ~ # tar -xzf 4.1.35.tar.gz 

Copy the files into place.

naomi ~ # cp 4.1.35/linux-4.1.tar.xz /usr/portage/distfiles/linux-4.1.tar.xz 
naomi ~ # cp 4.1.35/gentoo-sources/* /usr/portage/sys-kernel/gentoo-sources/

Create the manifest so that portage will see it as valid or whatever.

naomi ~ # ebuild /usr/portage/sys-kernel/gentoo-sources/gentoo-sources-4.1.35.ebuild digest

Now you can emerge it like usual and it'll install from your local files rather than from the internet.

naomi ~ # emerge --ask sys-kernel/gentoo-sources:4.1.35

I tested this on a machine that first installed the older kernel, but I don't see why it wouldn't work from scratch. That is, you should be able to do all this right before the emerge --ask --update --deep --newuse @world part of the instructions. And in that case, leave out the last step of this article's instructions.

Comment on this page.