raphael / linux-samus

Linux 4.16 on Chromebook Pixel 2015
GNU General Public License v2.0
181 stars 36 forks source link

How can others work on this project? #211

Closed christianbundy closed 4 years ago

christianbundy commented 6 years ago

Hi there! I've noticed that this project is a bit behind Linux v4.16.y and I'd like to help, but I've been having trouble trying to understand how this repository is set up. In the past I've just used git clone to pull your AUR repo and run makepkg -si, but while trying to mitigate #210 I've realized that I don't think I can build the repo from source.

I've read through all of the documentation and am under the impression that scripts/build.sh is a good place to start, but it looks like it's looking for the non-existent build/linux-patched. I've used git grep but can't find anything that could possibly generate build/linux-patched, and the patch references I found point to non-existent files.

After doing a deep-dive into the Git history I can see that there used to be files like scripts/patch.sh that look like they're capable of applying patches, but that seems to have been deleted. My best guess is that you've applied the patches to build/linux and are just manually copy and pasting changes from the Linux v4.16.y tree, which seems like build/linux is the patched version of Linux, which is getting changes copied from the stable tree and pasted into this repo. Could that be right? If so, I'd love to help out and delete all of the outdated scripts and documentation in the repo.

Given the above background info, I have two questions:

Thanks for working on this great kernel, it makes my life a hell of a lot easier.

raphael commented 6 years ago

Thank you for the interest! As noted in the README there is no need to patch the kernel anymore to get support for all the hardware. This is why the patch scripts were deleted. linux-patched is just a vanilla clone of the linux source code. build.sh is indeed the right script for building the kernel. You may also be interested in the platform specific build scripts in scripts/archlinux and scripts/debian. Finally there's a release.sh script which is what I use to build new releases. As you've noted I haven't built one in the past few releases because the kernel wouldn't compile. This is fixed as of 4.16.8 and I'm in the process of building a new release now.

christianbundy commented 6 years ago

Thanks for the quick response! It sounds like this repo contains a few different things:

Assuming that all of the CONFIG_ changes are intentional and still relevant, do you think it would be appropriate to remove the kernel from this repo and include a small patch for the vanilla kernel instead?


EDIT: I just realized that these CONFIG_ changes would be great to document. Some, like CONFIG_MCORE2=y are self-explanatory, but I'd love to get some more info on more obscure stuff like CONFIG_NODES_SHIFT=2 or CONFIG_X86_INTEL_MPX=y.

ehegnes commented 6 years ago

With respect to CONFIG_NODES_SHIFT, I don't think we can even properly use NUMA—our machines only have a single CPU socket. It might as well not be there.

I'd be glad to help document the configuration choices that this repo has made. Would this perhaps make more sense to document in a wiki section rather than including it in the README?

Edit: Also, thanks @christianbundy for so nicely itemizing deviations from the default config!

raphael commented 6 years ago

@christianbundy @ehegnes Would any of you be interested in taking over maintaining this repo and releasing new kernel versions? I'm finding myself with less and less time to spend on this.

ehegnes commented 6 years ago

@raphael, I'd be happy to give it a shot, long as you can outline the process you go through. It's been while since I dug into the scripts.

raphael commented 6 years ago

Great! the steps necessary to release a new kernel version are described in RELEASE.md. They are automated in the script release.sh located under the scripts folder.

The release process relies on the Linux kernel repo being cloned under scr/linux-patched (the term linux-patched is historic since there is no patching necessary anymore). The steps push the new package to the AUR which requires push access to the linux-samus4 repo. I can add you as a maintainer if you provide me with your username.

Maybe you can try running the release.sh script and see if you can get it to work then ask here if something isn't working quite right?

Thank you!

christianbundy commented 6 years ago

I'd be happy to help co-maintain or work on any future versions -- I've recently packaged the runtime scripts (like enable-speakers.sh) as an AUR package called [samus-scripts](https://aur.archlinux.org/packages/samus-scripts/ and I've been maintaining a small personal fork based on upstream linux for a few weeks as well.

ehegnes commented 6 years ago

@christianbundy Perhaps we should both maintain this repo so that it is more manageable. Nice job packaging the scripts.

@raphael I just created an AUR account—the username is the same as my GitHub.

raphael commented 6 years ago

@ehegnes I've added you as a co-maintainer of the AUR package.

@christianbundy let me know what your AUR username is and I'll add you as well.

Thank you guys!

christianbundy commented 6 years ago

Thanks @raphael! I've got the same username on AUR: https://aur.archlinux.org/account/christianbundy

raphael commented 6 years ago

Alright both of you are co-maintainers now.