Skip to content

How to build a new mariux kernel

Donald Buczek edited this page Jan 18, 2024 · 6 revisions

How to create a new Mariux64 kernel bee package

Clone or Update

Note: We call the upstream repository mariux64 instead of origin and specify its name explicitly to support that the same (persistent) local repository can be used to track multiple other remotes (e.g. linux, stable, ...) and it is unclear, which one should be the default.

Clone this repository into your local repository

cd /scratch/local2/
git clone --origin mariux64 git@github.molgen.mpg.de:mariux64/linux.git
cd linux

Update your local repository

cd /scratch/local2/linux
git fetch mariux64

Check out the relevant mariux64 branch

Note: All newly released kernels on kernel.org are automatically test-built and pushed into this repository. So we have a branch for every available release. This guide uses v6.6.12 as an example.

git checkout linux-6.6.12-mpi

Configure

cp config-mpi .config
make olddefconfig

Optional: Apply new configuration

If you want to change any config options, now is the time to do so. Don't forget the test runs.

make menuconfig
make -j $(nproc)
sudo mpi/install.sh
sudo mxgrub --reboot

Commit your configuration changes:

make savedefconfig
cp defconfig config-mpi
git commit -m"config-mpi: Enable BLABLAOPT" config-mpi
git push mariux64

Create a tag for the new Mariux64 kernel number

Use the Script next-kernel-number to easily find the next free Mariux64 kernel number. The create a release tag for that number and push it to the repository on github.

2DO: Import the script from bee-files into this repository

2DO/next-kernel-number
git tag mariux-6.6.12-461
git push mariux64 mariux-6.6.12-461

Create PR in bee-files

Assuming you have a bee-files repository on ~/git/bee-files

2DO: The SRCURL procedure is very ugly

cd ~/git/bee-files
git checkout master
git pull
git checkout -b add-linux-6.6.12
cp linux-6.6.11-460.bee linux-6.6.12-461.bee
vi linux-6.6.12-461.bee    # switch SRCURL to github URL
./linux-6.6.12-461.bee     # abort with ^C when download complete!
scripts/srcurl  /scratch/local/bee-USERNAME/linux/files/mariux-6.6.12-461.tar.gz
vi linux-6.6.12-461.bee    # switch back to beehive SRCURL as displayed by output of previous command
unshare -r ./linux-6.6.12-461.bee -c
git add linux-6.6.12-461.bee
git commit -m"linux: Add version 6.6.12" linux-6.6.12-461.bee

Optional: Build nvidia driver for the new kernel

cp nvidia_linux-6.6.11-460-535.104.05-0.bee nvidia_linux-6.6.12-461-535.104.05-0.bee
unshare -r ./nvidia_linux-6.6.12-461-535.104.05-0.bee
git add nvidia_linux-6.6.12-461-535.104.05-0.bee
git commit -m"nvidia_linux: Add version 535.104.05 for Linux 6.6.12-461"

Create PR

git push --set-upstream origin add-linux-6.6.12
firefox https://github.molgen.mpg.de/mariux64/bee-files/pull/new/add-linux-6.6.12
Clone this wiki locally