1
0

MAJ README.md

This commit is contained in:
Jybz
2019-12-19 19:57:34 +01:00
parent 756d128e4c
commit 82b0c397f8
5 changed files with 645 additions and 1172 deletions

View File

@ -1,4 +1,4 @@
#!/bin/bash -x
#!/bin/bash
# Copyright (C) 2017-2018 Daniel Tartavel-jeannot <contact@librepc.com>
# Copyright (C) 2019-2020 Jean-Baptiste Biernacki <j.biernacki@free.fr>
@ -77,11 +77,16 @@ export ARCH=arm
###########################################
# urpmi.update Testing
# urpmi --auto --media Testing kernel-desktop-latest
urpmi --auto kernel-desktop-latest
############################################
## Installing the kernel (not on testing) ##
############################################
# urpmi --auto kernel-desktop-latest
###############################################
## Create a symlink for the lastest kernel : ##
###############################################
## As long as the first installed kernel remains installed, the boot.scr script will continue to work, even if the extlinux.conf file is not working with uboot anymore.
# #Last rpm package :
# KERNELRPM=$(rpm -qa --last | grep "^kernel-[sd]e[[:alpha:]]*-[[:digit:]]" | head -n 1 | cut -d ' ' -f 1 | sed -e 's/\(kernel-[[:alnum:]]*-[\.[:digit:]]*-[\.[:alnum:]]*\)-.*/\1/' )
# #Get the vmlinuz file :
@ -91,6 +96,17 @@ VMLINUZ=$(ls --sort=time -1 /boot/vmlinuz-[[:digit:]]* | head -n 1)
rm -f /boot/uvmlinuz
ln -r -s "${VMLINUZ}" /boot/uvmlinuz
################################
## Create the extlinux script ##
################################
echo -e "\nTrying to generate extlinux script\n"
K_INST_VERSION=$(rpm -q kernel-desktop-latest | sed -e 's/kernel-\([[:alnum:]]*\)-latest-\([\.[:digit:]]*\)-\([\.[:alnum:]]*\).*$/\2-\1-\3/')
# /sbin/installkernel %{kversion}-$kernel_flavour-%{buildrpmrel}
# bash -x /sbin/installkernel ${K_INST_VERSION}
perl -d /usr/sbin/bootloader-config --kernel-version ${K_INST_VERSION} --initrd-options '' --action add-kernel
echo -e "\nEnd trying to generate extlinux script with errcode ${?}\n"
/usr/bin/chown :chrony -R /etc/chrony.keys /var/log/chrony
/usr/bin/chown :daemon /etc/wpa_supplicant.conf
@ -99,5 +115,5 @@ ln -r -s "${VMLINUZ}" /boot/uvmlinuz
/usr/bin/chown :bin /sbin/traceroute
/usr/bin/chown polkitd /etc/polkit-1/rules.d
# sleep 5s
#DO NOT EXIT THE SCRIPT. A second part is automatically added in this script during the process in order to create the default user and set root password.
## DO NOT EXIT THE SCRIPT. A second part is automatically added in this script during the process in order to create the default user and set root password.