various fixes
This commit is contained in:
parent
7ee7ce4ed1
commit
8706462a36
|
@ -1,5 +1,5 @@
|
||||||
A project in the works to convert an installed Slackware-15.0 system into a Freenix-15.0 system.
|
A project in the works to convert an installed Slackware-15.0 system into a Freenix-15.0 system.
|
||||||
Both 64-bit and 32-bit versions are covered.
|
Both 64-bit and 32-bit versions can be converted.
|
||||||
|
|
||||||
There are 4 scripts in total:
|
There are 4 scripts in total:
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@ BLACKLISTFILE = the location of your slackpkg blacklist file (default = /etc/sla
|
||||||
|
|
||||||
This builds and installs the Linux-Libre kernel, headers, modules.
|
This builds and installs the Linux-Libre kernel, headers, modules.
|
||||||
Modifies stock kernel-configs and SlackBuild files.
|
Modifies stock kernel-configs and SlackBuild files.
|
||||||
If the new kernel is much newer than the stock kernel, the build script will propmpt for new kernel configs.
|
|
||||||
|
|
||||||
arguments:
|
arguments:
|
||||||
|
|
||||||
|
|
|
@ -19,19 +19,19 @@ CWD0=$(pwd)
|
||||||
|
|
||||||
# future proof the release version number
|
# future proof the release version number
|
||||||
# to-do: make this work on -current?
|
# to-do: make this work on -current?
|
||||||
RELEASE=$(grep '^VERSION=' /etc/os-release | cut -d '=' -f 2 | sed 's/"//g')
|
RELEASE=${RELEASE:-$(grep '^VERSION=' /etc/os-release | cut -d '=' -f 2 | sed 's/"//g')}
|
||||||
|
|
||||||
# Uses mirrors.slackware.com to find a mirror near you, feel free to change to a local mirror
|
# Uses mirrors.slackware.com to find a mirror near you, feel free to change to a local mirror
|
||||||
REPOURL='https://mirrors.slackware.com'
|
REPOURL=${REPOURL:-'https://mirrors.slackware.com'}
|
||||||
|
|
||||||
# prepare for kernel building
|
# prepare for kernel building
|
||||||
BUILDDIR='/tmp/linux-libre-4-freenix'
|
BUILDDIR=${BUILDDIR:-'/tmp/linux-libre-4-freenix'}
|
||||||
|
|
||||||
# Set blacklist file, just in case...
|
# Set blacklist file, just in case...
|
||||||
BLACKLISTFILE='/etc/slackpkg/blacklist'
|
BLACKLISTFILE=${BLACKLISTFILE:-'/etc/slackpkg/blacklist'}
|
||||||
|
|
||||||
# Set variable to 'yes' to install package after building:
|
# Set variable to 'yes' to install package after building:
|
||||||
INSTALL_FIRMWARE='no'
|
INSTALL_FIRMWARE=${INSTALL_FIRMWARE:-'no'}
|
||||||
|
|
||||||
# download linux-libre firmware
|
# download linux-libre firmware
|
||||||
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
@ -70,7 +70,7 @@ echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
echo "% Building Linux-Libre firmware"
|
echo "% Building Linux-Libre firmware"
|
||||||
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
|
||||||
./kernel-firmware-gnu.SlackBuild
|
TMP=${BUILDDIR}/firmware ./kernel-firmware-gnu.SlackBuild
|
||||||
|
|
||||||
if [ $INSTALL_FIRMWARE == 'no' ]; then
|
if [ $INSTALL_FIRMWARE == 'no' ]; then
|
||||||
|
|
||||||
|
@ -95,7 +95,7 @@ echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
echo "% Installing Linux-Libre firmware"
|
echo "% Installing Linux-Libre firmware"
|
||||||
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
|
||||||
installpkg /tmp/kernel-firmware-gnu*
|
installpkg ${BUILDDIR}/firmware/kernel-firmware-gnu*
|
||||||
|
|
||||||
# Add non-free packages to blacklist if not already blacklisted
|
# Add non-free packages to blacklist if not already blacklisted
|
||||||
if ! grep -q "kernel-firmware" $BLACKLISTFILE ; then
|
if ! grep -q "kernel-firmware" $BLACKLISTFILE ; then
|
||||||
|
|
|
@ -18,25 +18,25 @@
|
||||||
CWD0=$(pwd)
|
CWD0=$(pwd)
|
||||||
|
|
||||||
# Set blacklist file, just in case...
|
# Set blacklist file, just in case...
|
||||||
BLACKLISTFILE='/etc/slackpkg/blacklist'
|
BLACKLISTFILE=${BLACKLISTFILE:-'/etc/slackpkg/blacklist'}
|
||||||
|
|
||||||
# Set variable to 'yes' to install packages after building:
|
# Set variable to 'yes' to install packages after building:
|
||||||
INSTALL_KERNEL='no'
|
INSTALL_KERNEL=${INSTALL_KERNEL:-'no'}
|
||||||
|
|
||||||
# future proof the release version number
|
# future proof the release version number
|
||||||
# to-do: make this work on -current?
|
# to-do: make this work on -current?
|
||||||
RELEASE=$(grep '^VERSION=' /etc/os-release | cut -d '=' -f 2 | sed 's/"//g')
|
RELEASE=${RELEASE:-$(grep '^VERSION=' /etc/os-release | cut -d '=' -f 2 | sed 's/"//g')}
|
||||||
|
|
||||||
# prepare for kernel building
|
# prepare for kernel building
|
||||||
BUILDDIR='/tmp/linux-libre-4-freenix'
|
BUILDDIR=${BUILDDIR:-'/tmp/linux-libre-4-freenix'}
|
||||||
rm -r ${BUILDDIR}
|
rm -r ${BUILDDIR}
|
||||||
mkdir ${BUILDDIR}
|
mkdir ${BUILDDIR}
|
||||||
cd ${BUILDDIR}
|
cd ${BUILDDIR}
|
||||||
|
|
||||||
# Uses mirrors.slackware.com to find a mirror near you, feel free to change to a local mirror
|
# Uses mirrors.slackware.com to find a mirror near you, feel free to change to a local mirror
|
||||||
REPOURL='https://mirrors.slackware.com'
|
REPOURL=${REPOURL:-'https://mirrors.slackware.com'}
|
||||||
# Set latest stock version here
|
# Set latest stock version here
|
||||||
STOCKVERSION=$(wget -q -O - $REPOURL/slackware/slackware64-$RELEASE/patches/source/ | grep -o -P '(?<=>linux-).*(?=\/<)')
|
STOCKVERSION=${STOCKVERSION:-$(wget -q -O - $REPOURL/slackware/slackware64-$RELEASE/patches/source/ | grep -o -P '(?<=>linux-).*(?=\/<)')}
|
||||||
|
|
||||||
# download kernel SlackBuild scripts
|
# download kernel SlackBuild scripts
|
||||||
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
@ -54,7 +54,7 @@ sed -i 's/oldconfig/olddefconfig/' kernel-modules.SlackBuild
|
||||||
sed -i 's/oldconfig/olddefconfig/' kernel-source.SlackBuild
|
sed -i 's/oldconfig/olddefconfig/' kernel-source.SlackBuild
|
||||||
|
|
||||||
# use MAJORVERSION to change branches if you wish
|
# use MAJORVERSION to change branches if you wish
|
||||||
MAJORVERSION=$(wget -q -O - $REPOURL/slackware/slackware64-$RELEASE/patches/source/ | grep -o -P '(?<=>linux-).*(?=\/<)' | sed 's/\.[^.]*$//')
|
MAJORVERSION=${MAJORVERSION:-$(wget -q -O - $REPOURL/slackware/slackware64-$RELEASE/patches/source/ | grep -o -P '(?<=>linux-).*(?=\/<)' | sed 's/\.[^.]*$//')}
|
||||||
|
|
||||||
# download latest Linux-Libre source in the same branch as the stock kernel
|
# download latest Linux-Libre source in the same branch as the stock kernel
|
||||||
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
|
||||||
|
@ -65,7 +65,7 @@ wget -r -l1 -np -nd "http://linux-libre.fsfla.org/pub/linux-libre/releases/LATES
|
||||||
wget http://linux-libre.fsfla.org/pub/linux-libre/SIGNING-KEY.linux-libre
|
wget http://linux-libre.fsfla.org/pub/linux-libre/SIGNING-KEY.linux-libre
|
||||||
gpg --import SIGNING-KEY.linux-libre
|
gpg --import SIGNING-KEY.linux-libre
|
||||||
gpg --verify *tar.lz.sign
|
gpg --verify *tar.lz.sign
|
||||||
LIBREVERSION=$(ls linux-libre-*-gnu.tar.lz | sed 's/[^0-9.]*//g' | sed 's/..$//')
|
LIBREVERSION=${LIBREVERSION:-$(ls linux-libre-*-gnu.tar.lz | sed 's/[^0-9.]*//g' | sed 's/..$//')}
|
||||||
|
|
||||||
ln -s linux-libre-${LIBREVERSION}-gnu.tar.lz linux-${LIBREVERSION}.tar.lz
|
ln -s linux-libre-${LIBREVERSION}-gnu.tar.lz linux-${LIBREVERSION}.tar.lz
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
####################################################################################
|
####################################################################################
|
||||||
|
|
||||||
# Set blacklist file, just in case...
|
# Set blacklist file, just in case...
|
||||||
BLACKLISTFILE="/etc/slackpkg/blacklist"
|
BLACKLISTFILE=${BLACKLISTFILE:-"/etc/slackpkg/blacklist"}
|
||||||
|
|
||||||
# Remove non-free stock packages from full stock installation
|
# Remove non-free stock packages from full stock installation
|
||||||
# Comment out any you'd like to keep
|
# Comment out any you'd like to keep
|
||||||
|
|
Loading…
Reference in New Issue