aboutsummaryrefslogtreecommitdiff
path: root/grs
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2018-04-14 10:52:57 -0400
committerAnthony G. Basile <blueness@gentoo.org>2018-04-14 10:52:57 -0400
commit4eea4b02f33038cbf8d0ea706dd212df964cac4a (patch)
tree82649548d1c505c47262d773fc132b530ce6aa53 /grs
parentgrs/Kernel.py: allow genkernel to install firmware (diff)
downloadgrss-4eea4b02f33038cbf8d0ea706dd212df964cac4a.tar.gz
grss-4eea4b02f33038cbf8d0ea706dd212df964cac4a.tar.bz2
grss-4eea4b02f33038cbf8d0ea706dd212df964cac4a.zip
grs/Kernel.py: look for firmware-dir in portage_configroot
Diffstat (limited to 'grs')
-rw-r--r--grs/Kernel.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/grs/Kernel.py b/grs/Kernel.py
index 7582e81..82e6d04 100644
--- a/grs/Kernel.py
+++ b/grs/Kernel.py
@@ -92,6 +92,10 @@ class Kernel():
boot_dir = os.path.join(image_dir, 'boot')
modprobe_dir = os.path.join(image_dir, 'etc/modprobe.d')
modules_dir = os.path.join(image_dir, 'lib/modules')
+
+ # The firmware directory, if it exists, will be in self.portage_configroot
+ firmware_dir = os.path.join(self.portage_configroot, 'lib/firmware')
+
# Prepare tarball filename and path. If the tarball already exists,
# don't rebuild/reinstall it. Note: It should have been installed to
# the system's portage configroot when it was first built, so no need
@@ -132,6 +136,8 @@ class Kernel():
cmd += '--busybox-config=%s ' % self.busybox_config
if os.path.isfile(self.genkernel_config):
cmd += '--config=%s ' % self.genkernel_config
+ if os.path.isdir(firmware_dir):
+ cmd += '--firmware-dir=%s ' % firmware_dir
if has_modules:
cmd += 'all'
else: