Freenix
Freenix forum

Home » Community » General Info and Discussion » Scripts to build (kernel packages)
Re: Scripts to build [message #45 is a reply to message #44] Tue, 05 March 2019 18:25 Go to previous messageGo to previous message
samtux is currently offline  samtux
Messages: 3
Registered: January 2017
Location: Germany
Junior Member
Here are the steps that worked for me to build the kernel package for Freenix 14.2. I'm not sure which is the recommended way how to do it, though.

1. Download the build scripts from the command line prompt as non-root user:
lftp -c "open https://freenix.net/fxp/freeslack64-14.2/source/fxp/build/; mirror linux-libre" && cd linux-libre
curl https://freenix.net/fxp/freeslack64-14.2/source/fxp/build/linux-libre/README > README.TXT

2. Get the source of the latest 4.4.x kernel version and install it manually, without building a package:
Set a variable for the download path we use later on:
SRC_URL=http://linux-libre.fsfla.org/pub/linux-libre/releases/LATEST-4.4.N
Find the latest 4.4.x kernel source and put it to another variable:
SRC_ARCH=`curl -s $SRC_URL/ | egrep -o "linux-libre-4\.4\.[0-9]+-gnu.tar.bz2" | head -n1`
Set a version variable:
VERSION=`egrep -o "4\.4\.[0-9]+" <<<$SRC_ARCH`
Download the source archive:
wget $SRC_URL/$SRC_ARCH
Unpack the source archive to /usr/src/:
su -c "cd /usr/src; tar -xvf "`pwd`"/$SRC_ARCH && ln -sv linux-$VERSION linux"

3. Copy the downloaded config files to /usr/src/:
su -c "cp -v config-generic-4.4.*.x64 /usr/src/linux/config-generic && cp -v config-huge-4.4.*.x64 /usr/src/linux/config-huge"

4. Build the kernel image package:
su - -c "cd "`pwd`"; bash linux-libre-image.SlackBuild"

5. Read the downloaded README.TXT for instructions on further installation steps.

I didn't use the linux-libre-source.SlackBuild script, since it doesn't extract the kernel source archive but only copies it to /usr/src/, and I don't know what's the benefit of installing a Package, which copies an archive that isn't used by any program or script, and only becomes usable after extracting it manually, and also other steps are needed, like copying the config files and the README.TXT, in order to work with the image build script.

I hope this helps.
 
Read Message
Read Message
Read Message
Previous Topic: Install on X200
Next Topic: Thoughts on Freenix64-15.0
Goto Forum:
  


Current Time: Sat Apr 27 00:34:39 EDT 2024

Total time taken to generate the page: 0.00847 seconds