summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2003-10-22 20:01:02 +0000
committerJeremy Katz <katzj@redhat.com>2003-10-22 20:01:02 +0000
commitcf648d51edb76a31ce02a1a2f29100c4a3af7c48 (patch)
treed199b64551412662bea85d722b47dfd8ebfd02f0
parent7f5d3cec9b4a06d4155010e4e50134611557f4f3 (diff)
downloadanaconda-cf648d51edb76a31ce02a1a2f29100c4a3af7c48.tar.gz
anaconda-cf648d51edb76a31ce02a1a2f29100c4a3af7c48.tar.xz
anaconda-cf648d51edb76a31ce02a1a2f29100c4a3af7c48.zip
'linux lilo' will get you lilo back now.
*sigh*
-rw-r--r--bootloader.py9
-rw-r--r--iw/bootloader_main_gui.py5
-rw-r--r--textw/bootloader_text.py3
3 files changed, 14 insertions, 3 deletions
diff --git a/bootloader.py b/bootloader.py
index 323b0d875..e044ac9a0 100644
--- a/bootloader.py
+++ b/bootloader.py
@@ -32,6 +32,15 @@ from rhpl.translate import _
from booty import *
from bootloaderInfo import *
+showLilo = 0
+try:
+ f = open("/proc/cmdline", "r")
+ if f.read().find("lilo") != -1:
+ showLilo = 1
+except:
+ pass
+
+
def bootloaderSetupChoices(dispatch, bl, fsset, diskSet, dir):
if dir == DISPATCH_BACK:
diff --git a/iw/bootloader_main_gui.py b/iw/bootloader_main_gui.py
index cac231757..761383608 100644
--- a/iw/bootloader_main_gui.py
+++ b/iw/bootloader_main_gui.py
@@ -18,6 +18,7 @@ import gobject
import iutil
import partedUtils
import gui
+import bootloader
from iw_gui import *
from rhpl.translate import _, N_
@@ -137,7 +138,7 @@ class MainBootloaderWindow(InstallWindow):
self.grub_radio = gtk.RadioButton(None, (_("Use _GRUB as the "
"boot loader")))
- if 0:
+ if bootloader.showLilo:
self.lilo_radio = gtk.RadioButton(self.grub_radio,
(_("Use _LILO as the boot "
"loader")))
@@ -156,7 +157,7 @@ class MainBootloaderWindow(InstallWindow):
if self.blname is None:
self.none_radio.set_active(gtk.TRUE)
- elif 0 and self.blname == "LILO" and iutil.getArch() == "i386":
+ elif self.lilo_radio is not None and self.blname == "LILO" and iutil.getArch() == "i386":
self.lilo_radio.set_active(gtk.TRUE)
else:
self.grub_radio.set_active(gtk.TRUE)
diff --git a/textw/bootloader_text.py b/textw/bootloader_text.py
index d312e2a13..8ca4e469c 100644
--- a/textw/bootloader_text.py
+++ b/textw/bootloader_text.py
@@ -18,6 +18,7 @@ from flags import flags
from rhpl.log import log
import string
import iutil
+import bootloader
class BootloaderChoiceWindow:
@@ -41,7 +42,7 @@ class BootloaderChoiceWindow:
blradio = RadioGroup()
grub = blradio.add(_("Use GRUB Boot Loader"), "grub", useGrub)
- if 0 and iutil.getArch() == "i386":
+ if bootloader.showLilo and iutil.getArch() == "i386":
lilo = blradio.add(_("Use LILO Boot Loader"), "lilo", useLilo)
else:
lilo = None