change messages to comments

This commit is contained in:
Tobias Powalowski 2023-10-25 22:20:23 +02:00
parent c8cfe22782
commit 7893df308a
2 changed files with 4 additions and 3 deletions

View file

@ -86,6 +86,7 @@ _install_libs
if [[ -z "${_MODS}" && -z "${_MOD_DEPS}" ]]; then if [[ -z "${_MODS}" && -z "${_MOD_DEPS}" ]]; then
echo "Skipping kernel modules..." echo "Skipping kernel modules..."
else else
echo "Adding kernel modules..."
_install_mods _install_mods
fi fi
ldconfig -r "${_ROOTFS}" &>"${_NO_LOG}" || exit 1 ldconfig -r "${_ROOTFS}" &>"${_NO_LOG}" || exit 1

View file

@ -178,7 +178,7 @@ _run_hook() {
} }
_install_mods() { _install_mods() {
echo "Checking kernel module dependencies..." # Checking kernel module dependencies:
# first try, pull in the easy modules # first try, pull in the easy modules
_MOD_DEPS="$(modinfo -k "${_KERNELVERSION}" -F depends $_MODS 2>/dev/null | sed -e 's#,# #g' | tr " " "\n" | sort -u) \ _MOD_DEPS="$(modinfo -k "${_KERNELVERSION}" -F depends $_MODS 2>/dev/null | sed -e 's#,# #g' | tr " " "\n" | sort -u) \
$(modinfo -k "${_KERNELVERSION}" -F softdep $_MODS 2>/dev/null | sed -e 's#.*: # #g' | tr " " "\n" | sort -u)" $(modinfo -k "${_KERNELVERSION}" -F softdep $_MODS 2>/dev/null | sed -e 's#.*: # #g' | tr " " "\n" | sort -u)"
@ -195,13 +195,13 @@ _install_mods() {
done done
_map _file "${_MODULE_DIR}"/modules.{builtin,builtin.modinfo,order} _map _file "${_MODULE_DIR}"/modules.{builtin,builtin.modinfo,order}
_install_files _install_files
echo "Adding kernel modules..." # Adding kernel modules:
# - pull in all modules with depends # - pull in all modules with depends
# - builtin needs to be removed # - builtin needs to be removed
# - all starting / needs to be removed from paths # - all starting / needs to be removed from paths
tar --hard-dereference -C / -cpf - $(modinfo -k "${_KERNELVERSION}" -F filename $_MODS $_MOD_DEPS 2>/dev/null \ tar --hard-dereference -C / -cpf - $(modinfo -k "${_KERNELVERSION}" -F filename $_MODS $_MOD_DEPS 2>/dev/null \
| grep -v builtin | sed -e 's#^/##g' -e 's# /# #g') | tar -C "${_ROOTFS}" -xpf - | grep -v builtin | sed -e 's#^/##g' -e 's# /# #g') | tar -C "${_ROOTFS}" -xpf -
echo "Generating new kernel module dependencies..." # generate new kernel module dependencies"
depmod -b "${_ROOTFS}" "${_KERNELVERSION}" depmod -b "${_ROOTFS}" "${_KERNELVERSION}"
# remove all non-binary module.* files (except devname for on-demand module loading # remove all non-binary module.* files (except devname for on-demand module loading
# and builtin.modinfo for checking on builtin modules) # and builtin.modinfo for checking on builtin modules)