From ff6ecb80a4e71b2acf7bcf0945bbbf57012ae430 Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@cd1c1023-2f26-0410-ae45-c471fc1f0318> Date: Mon, 10 Mar 2008 09:28:25 +0000 Subject: [PATCH] fix grub.conf configuration for kernels in a separate /boot partition git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@1435 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- TODO | 1 + libraries/entropy.py | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/TODO b/TODO index dd6121296..989586c41 100644 --- a/TODO +++ b/TODO @@ -1,4 +1,5 @@ TODO list: + - add "equo match" tool - make an ETP_DIR switching function - lilo.conf trigger? - equo: "you meant...?" feature diff --git a/libraries/entropy.py b/libraries/entropy.py index 8be1a8225..e88e33f18 100644 --- a/libraries/entropy.py +++ b/libraries/entropy.py @@ -5738,11 +5738,19 @@ class TriggerInterface: # FIXME: this only supports grub (no lilo support) def trigger_addbootablekernel(self): + boot_mount = False + if os.path.ismount("/boot"): + boot_mount = True kernels = [x for x in self.pkgdata['content'] if x.startswith("/boot/kernel-")] + if boot_mount: + kernels = [x[len("/boot"):] for x in kernels] for kernel in kernels: initramfs = "/boot/initramfs-"+kernel[13:] if initramfs not in self.pkgdata['content']: initramfs = '' + elif boot_mount: + initramfs = initramfs[len("/boot"):] + # configure GRUB self.Entropy.equoLog.log(ETP_LOGPRI_INFO,ETP_LOGLEVEL_NORMAL,"[POST] Configuring GRUB bootloader. Adding the new kernel...") self.Entropy.updateProgress(