Run the depmod after compressing the modules

Also create the etc/modprobe.d directory in the initrd image
This commit is contained in:
Martin Gracik 2010-03-26 08:49:58 +01:00
parent f35031e623
commit bcea8cdcdd
2 changed files with 14 additions and 13 deletions

View File

@ -108,9 +108,11 @@ copy "usr/libexec/nm-*"
copy "usr/share/dbus-1/system-services/org.freedesktop.nm_dispatcher.service"
## modprobe
makedirs "etc/modprobe.d"
copy "sbin/modprobe"
copy "sbin/insmod"
copy "sbin/rmmod"
copy "sbin/depmod"
## terminfos
copy "usr/share/terminfo/a/ansi"
@ -181,7 +183,6 @@ copy "etc/rsyslog.conf"
## missing files
copy "sbin/depmod"
copy "usr/sbin/sshd"
copy "usr/bin/ssh-keygen"
copy "usr/bin/strace"

View File

@ -290,18 +290,6 @@ export PS1 PATH
# remove the source module-info
#os.unlink(moduleinfo)
# run depmod
systemmap = os.path.join(self.srctree, self.const.BOOTDIR,
"System.map-{0}".format(kernel.version))
cmd = "{0.DEPMOD} -a -F {1} -b {2} {3}"
cmd = cmd.format(self.cmd, systemmap,
self.srctree, kernel.version)
err, stdout = commands.getstatusoutput(cmd)
if err:
self.perror(stdout)
# compress modules
for root, dirs, files in os.walk(dst_moddir):
for file in filter(lambda f: f.endswith(".ko"), files):
@ -314,6 +302,18 @@ export PS1 PATH
gzipped.close()
os.unlink(path)
# run depmod
systemmap = os.path.join(self.srctree, self.const.BOOTDIR,
"System.map-{0}".format(kernel.version))
cmd = "{0.DEPMOD} -a -F {1} -b {2} {3}"
cmd = cmd.format(self.cmd, systemmap,
self.srctree, kernel.version)
err, stdout = commands.getstatusoutput(cmd)
if err:
self.perror(stdout)
def get_keymaps(self):
override = "keymaps-override-{0}".format(self.conf.basearch)
override = os.path.join(self.srctree, self.const.ANACONDA_RUNTIME,