[2025-jun-17] The SlackDocs mailing lists at https://lists.alienbase.nl/mailman/listinfo have been retired. No one has been using these lists for years and it's time to say goodbye. The list archives remain available at https://scalzi.slackware.nl/mailman/listinfo/slackdocs
[2025-jun-17] The SlackDocs Wiki has moved to a new server, in order to make it more performant.
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
slackwarearm:cstmz_kernel_rpi_selfbuild [2023/06/06 16:06 (UTC)] – created mozes | slackwarearm:cstmz_kernel_rpi_selfbuild [2023/06/08 16:51 (UTC)] (current) – mozes | ||
---|---|---|---|
Line 1: | Line 1: | ||
[[https:// | [[https:// | ||
- | ====== Building | + | ====== Building Slackware AArch64 Linux Kernel |
^ ^ ^ | ^ ^ ^ | ||
| Document | Describe how to self-build Slackware Kernel packages from the Raspberry Pi Kernel fork | | | Document | Describe how to self-build Slackware Kernel packages from the Raspberry Pi Kernel fork | | ||
- | | Version | 1.01, May 2023 | | + | | Version | 1.00, June 2023 | |
| Author | Stuart Winter < | | Author | Stuart Winter < | ||
- | | See Also |[[slackwarearm: | + | | See Also | * [[slackwarearm: |
+ | |||
+ | === The Slackware ARM/AArch64 build system === | ||
+ | |||
+ | The Slackware ARM build system was built to abstract the common functionality of the build scripts into a library and configuration file, enabling global changes to be made in a single location. | ||
+ | |||
+ | The Slackware ARM source tree works as an ' | ||
+ | |||
+ | === Assumptions === | ||
+ | |||
+ | This document assumes that you're building on a full Slackware system, because the Slackware Linux Kernel package build process requires a number of development tools to be available. | ||
+ | |||
+ | This document provides some basic instructions using the '' | ||
+ | <note tip> | ||
+ | |||
+ | If you don't have '' | ||
+ | |||
+ | This document covers working on Slackware '' | ||
+ | |||
+ | ===== Preparing the environment ===== | ||
+ | |||
+ | === Download the Slackware AArch64 source tree === | ||
+ | |||
+ | Within your home directory, create a directory to contain the Slackware AArch64 source tree: | ||
+ | |||
+ | < | ||
+ | $ cd # return to the root of your home directory (not the ' | ||
+ | $ mkdir slackware ; cd slackware | ||
+ | </ | ||
+ | |||
+ | Determine where you are in the file system, as you will need this shortly: | ||
+ | |||
+ | < | ||
+ | $ pwd | ||
+ | / | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | $ rsync \ | ||
+ | | ||
+ | | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | |||
+ | <note important> | ||
+ | |||
+ | |||
+ | ==== Install the prerequisite packages ==== | ||
+ | |||
+ | Before the Kernel can be built, you need to ensure that you have certain packages installed. | ||
+ | This list isn't fully inclusive because you should build the Kernel on a full system, but particularly for Slackware -current, you need to ensure that you have the latest version of the Kernel packages installed so that it's aligned with the Slackware AArch64 source tree. | ||
+ | |||
+ | <note tip>If the packages aren't available for installation, | ||
+ | |||
+ | === Update slackpkg' | ||
+ | |||
+ | As **root**: | ||
+ | < | ||
+ | # slackpkg update | ||
+ | </ | ||
+ | |||
+ | == Install the Slackware ARM development kit == | ||
+ | |||
+ | The Slackware ARM build system uses a package named '' | ||
+ | This package is installed by default, but if you don't have it : | ||
+ | |||
+ | As **root**, install/ | ||
+ | < | ||
+ | # slackpkg install slackkit | ||
+ | </ | ||
+ | |||
+ | == Install other dependencies == | ||
+ | |||
+ | This list isn't exhaustive but should cover it (if more dependencies are required, please drop mozes@slackware.com a mail with them and I'll update this doc!) | ||
+ | |||
+ | < | ||
+ | # slackpkg install eudev mdadm lvm2 device-tree-compiler rsync | ||
+ | </ | ||
+ | |||
+ | ==== Configure the Slackware ARM build system ==== | ||
+ | |||
+ | <note tip>In this example the directory into which the Slackware AArch64 source tree was downloaded is ''/ | ||
+ | |||
+ | As **root**, you need to set up some symlinks to the location of your Slackware AArch64 source tree. | ||
+ | |||
+ | < | ||
+ | # cd # return to root's home directory | ||
+ | # ln -vfs / | ||
+ | # ln -vfs / | ||
+ | </ | ||
+ | |||
+ | ==== Alternate Kernel source package building tool ==== | ||
+ | |||
+ | There is a script within the Slackware AArch64 Kernel source directory ('' | ||
+ | |||
+ | It uses a ' | ||
+ | |||
+ | Elevate privileges to '' | ||
+ | |||
+ | < | ||
+ | |||
+ | Enter the directory in which the Slackware AArch64 source is stored. | ||
+ | |||
+ | < | ||
+ | |||
+ | == General settings == | ||
+ | |||
+ | The default settings should be good for most users, but note that by default it will need about 3G bytes of space in ''/ | ||
+ | If you don't have enough space, you should run it with the relevant command line operator '' | ||
+ | |||
+ | The script supports the '' | ||
+ | |||
+ | < | ||
+ | # ./ | ||
+ | </ | ||
+ | |||
+ | == Raspberry Pi Kernel fork git repository settings == | ||
+ | |||
+ | By default the tool is configured for the Raspberry Pi Kernel fork online git repository, as this is what this author uses to build [[slackwarearm: | ||
+ | |||
+ | The Raspberry Pi settings can be found in '' | ||
+ | |||
+ | For most users you'll want to use the default settings. | ||
+ | |||
+ | == Check which version of the Kernel will be built == | ||
+ | |||
+ | First, check what version of the Linux Kernel is available at the repository: | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | |||
+ | --------------------------- | ||
+ | Temporary directory.........: | ||
+ | Kernel source directory.....: | ||
+ | Package store directory.....: | ||
+ | |||
+ | GIT repository..............: | ||
+ | Kernel branch...............: | ||
+ | Slackware package build tag : 1_rpi | ||
+ | Save Kernel headers package : No | ||
+ | |||
+ | Hardware Model helper script: / | ||
+ | --------------------------- | ||
+ | |||
+ | Kernel version in web repository https:// | ||
+ | </ | ||
+ | |||
+ | == Build the Kernel == | ||
+ | |||
+ | Continuing as root, run the build script: | ||
+ | |||
+ | < | ||
+ | # ./ | ||
+ | </ | ||
+ | |||
+ | === Transitioning to the RPi Kernel fork Slackware packages === | ||
+ | |||
+ | After a few hours your Kernel will have been built, with the packages (by default) placed within ''/ | ||
+ | |||
+ | You should read the [[slackwarearm: | ||
+ | |||