Make use of firmware-misc-nonfree to more reliably install non-free firmware
This commit is contained in:
parent
7785bde220
commit
fd4d06f803
@ -1,2 +1,3 @@
|
||||
sources-proprietary
|
||||
firmware-proprietary-prereq
|
||||
firmware-proprietary
|
3
mods/firmware-proprietary-prereq/data/chroot
Executable file
3
mods/firmware-proprietary-prereq/data/chroot
Executable file
@ -0,0 +1,3 @@
|
||||
#!/usr/bin/env bash
|
||||
set -e
|
||||
apt-get -y install python3-apt
|
@ -1,13 +1,10 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
function sfp {
|
||||
packages=""
|
||||
while read p; do
|
||||
IFS=" " read -ra packageinfo <<< "$p"
|
||||
if [[ "${packageinfo[0]}" == *firmware* ]]; then
|
||||
packages="$packages ${packageinfo[0]}"
|
||||
fi
|
||||
done <<<$(apt-cache search "$1")
|
||||
echo "$packages"
|
||||
}
|
||||
echo "WDVN_PACKAGES=\"\$WDVN_PACKAGES firmware-linux firmware-misc-nonfree amd64-microcode intel-microcode $(sfp wireless) $(sfp wifi) $(sfp net) $(sfp nic)\"" >"/chroot-out"
|
||||
#!/usr/bin/env python3
|
||||
import apt
|
||||
cache = apt.Cache()
|
||||
ofile = open("/chroot-out","w",encoding="utf-8")
|
||||
ofile.write('WDVN_PACKAGES="$WDVN_PACKAGES')
|
||||
for package in cache:
|
||||
if package.candidate.origins[0].component == "non-free-firmware":
|
||||
ofile.write(" " + package.name)
|
||||
ofile.write('"')
|
||||
ofile.close()
|
Loading…
Reference in New Issue
Block a user