diff options
author | Chris Lumens <clumens@redhat.com> | 2009-02-26 11:33:40 -0500 |
---|---|---|
committer | Chris Lumens <clumens@redhat.com> | 2009-03-04 15:37:04 -0500 |
commit | f00ec6b554eece6689e71c50ff0eb59ad2549b54 (patch) | |
tree | c84d11ac1ed8d9780aedc67d2aea0ba01be814f2 /booty | |
parent | 930cac9c0de1480543f25c411110d9f615e34693 (diff) | |
download | anaconda-f00ec6b554eece6689e71c50ff0eb59ad2549b54.tar.gz anaconda-f00ec6b554eece6689e71c50ff0eb59ad2549b54.tar.xz anaconda-f00ec6b554eece6689e71c50ff0eb59ad2549b54.zip |
Don't use rhpl.executil anymore.
Diffstat (limited to 'booty')
-rw-r--r-- | booty/alpha.py | 6 | ||||
-rw-r--r-- | booty/bootloaderInfo.py | 27 | ||||
-rw-r--r-- | booty/ppc.py | 11 | ||||
-rw-r--r-- | booty/s390.py | 4 | ||||
-rw-r--r-- | booty/sparc.py | 11 | ||||
-rw-r--r-- | booty/x86.py | 20 |
6 files changed, 39 insertions, 40 deletions
diff --git a/booty/alpha.py b/booty/alpha.py index 5e62c93ca..d56c4cadd 100644 --- a/booty/alpha.py +++ b/booty/alpha.py @@ -1,5 +1,5 @@ import os -import rhpl.executil +import iutil from bootloaderInfo import * import fsset @@ -109,7 +109,7 @@ class alphaBootloaderInfo(bootloaderInfo): # to and the second argument is a path to the bootstrap loader # file. args = ("swriteboot", ("/dev/%s" % wbd), "/boot/bootlx") - rhpl.executil.execWithRedirect ('/sbin/swriteboot', args, + iutil.execWithRedirect ('/sbin/swriteboot', args, root = instRoot, stdout = "/dev/tty5", stderr = "/dev/tty5") @@ -120,7 +120,7 @@ class alphaBootloaderInfo(bootloaderInfo): # It's always the boot partition whether it's / or /boot (with # the mount point being omitted.) args = ("abootconf", ("/dev/%s" % wbd), str (bdpn)) - rhpl.executil.execWithRedirect ('/sbin/abootconf', args, + iutil.execWithRedirect ('/sbin/abootconf', args, root = instRoot, stdout = "/dev/tty5", stderr = "/dev/tty5") diff --git a/booty/bootloaderInfo.py b/booty/bootloaderInfo.py index 73d2781d3..b44219310 100644 --- a/booty/bootloaderInfo.py +++ b/booty/bootloaderInfo.py @@ -27,7 +27,6 @@ from copy import copy from lilo import LiloConfigFile import rhpl from rhpl.translate import _, N_ -import rhpl.executil from flags import flags from fsset import getDiskPart @@ -67,16 +66,16 @@ def syncDataToDisk(dev, mntpt, instRoot = "/"): # and xfs is even more "special" (#117968) if isys.readFSType(dev) == "xfs": - rhpl.executil.execWithRedirect( "/usr/sbin/xfs_freeze", - ["/usr/sbin/xfs_freeze", "-f", mntpt], - stdout = "/dev/tty5", - stderr = "/dev/tty5", - root = instRoot) - rhpl.executil.execWithRedirect( "/usr/sbin/xfs_freeze", - ["/usr/sbin/xfs_freeze", "-u", mntpt], - stdout = "/dev/tty5", - stderr = "/dev/tty5", - root = instRoot) + iutil.execWithRedirect("/usr/sbin/xfs_freeze", + ["/usr/sbin/xfs_freeze", "-f", mntpt], + stdout = "/dev/tty5", + stderr = "/dev/tty5", + root = instRoot) + iutil.execWithRedirect("/usr/sbin/xfs_freeze", + ["/usr/sbin/xfs_freeze", "-u", mntpt], + stdout = "/dev/tty5", + stderr = "/dev/tty5", + root = instRoot) def rootIsDevice(dev): if dev.startswith("LABEL=") or dev.startswith("UUID="): @@ -589,7 +588,7 @@ class efiBootloaderInfo(bootloaderInfo): # XXX wouldn't it be nice to have a real interface to use efibootmgr from? def removeOldEfiEntries(self, instRoot): p = os.pipe() - rhpl.executil.execWithRedirect('/usr/sbin/efibootmgr', ["efibootmgr"], + iutil.execWithRedirect('/usr/sbin/efibootmgr', ["efibootmgr"], root = instRoot, stdout = p[1]) os.close(p[1]) @@ -606,7 +605,7 @@ class efiBootloaderInfo(bootloaderInfo): continue if string.join(fields[1:], " ") == productName: entry = fields[0][4:8] - rhpl.executil.execWithRedirect('/usr/sbin/efibootmgr', + iutil.execWithRedirect('/usr/sbin/efibootmgr', ["efibootmgr", "-b", entry, "-B"], root = instRoot, stdout="/dev/tty5", stderr="/dev/tty5") @@ -636,7 +635,7 @@ class efiBootloaderInfo(bootloaderInfo): argv = [ "/usr/sbin/efibootmgr", "-c" , "-w", "-L", productName, "-d", "/dev/%s" % bootdisk, "-p", bootpart, "-l", "\\EFI\\redhat\\" + self.bootloader ] - rhpl.executil.execWithRedirect(argv[0], argv, root = instRoot, + iutil.execWithRedirect(argv[0], argv, root = instRoot, stdout = "/dev/tty5", stderr = "/dev/tty5") diff --git a/booty/ppc.py b/booty/ppc.py index 26881ec80..24a5df8fa 100644 --- a/booty/ppc.py +++ b/booty/ppc.py @@ -3,6 +3,7 @@ import os from bootloaderInfo import * import fsset +import iutil import rhpl class ppcBootloaderInfo(bootloaderInfo): @@ -146,11 +147,11 @@ class ppcBootloaderInfo(bootloaderInfo): ybinargs = [ yabootProg, "-f", "-C", cf ] if not flags.test: - rhpl.executil.execWithRedirect(ybinargs[0], - ybinargs, - stdout = "/dev/tty5", - stderr = "/dev/tty5", - root = instRoot) + iutil.execWithRedirect(ybinargs[0], + ybinargs, + stdout = "/dev/tty5", + stderr = "/dev/tty5", + root = instRoot) if (not os.access(instRoot + "/etc/yaboot.conf", os.R_OK) and os.access(instRoot + "/boot/etc/yaboot.conf", os.R_OK)): diff --git a/booty/s390.py b/booty/s390.py index d48030d55..a1857363c 100644 --- a/booty/s390.py +++ b/booty/s390.py @@ -2,7 +2,7 @@ import os from bootloaderInfo import * import fsset -import rhpl +import iutil class s390BootloaderInfo(bootloaderInfo): def getBootloaderConfig(self, instRoot, fsset, bl, kernelList, @@ -159,7 +159,7 @@ class s390BootloaderInfo(bootloaderInfo): if not justConfigFile: argv = [ "/sbin/zipl" ] - rhpl.executil.execWithRedirect(argv[0], argv, root = instRoot, + iutil.execWithRedirect(argv[0], argv, root = instRoot, stdout = "/dev/stdout", stderr = "/dev/stderr") diff --git a/booty/sparc.py b/booty/sparc.py index 471caa060..a9cfaf83f 100644 --- a/booty/sparc.py +++ b/booty/sparc.py @@ -2,7 +2,6 @@ import os from bootloaderInfo import * import fsset -import rhpl class sparcBootloaderInfo(bootloaderInfo): def writeSilo(self, instRoot, fsset, bl, kernelList, @@ -94,11 +93,11 @@ class sparcBootloaderInfo(bootloaderInfo): sbinargs += ["-U"] if not flags.test: - rhpl.executil.execWithRedirect(sbinargs[0], - sbinargs, - stdout = "/dev/tty5", - stderr = "/dev/tty5", - root = instRoot) + iutil.execWithRedirect(sbinargs[0], + sbinargs, + stdout = "/dev/tty5", + stderr = "/dev/tty5", + root = instRoot) if (not os.access(instRoot + "/etc/silo.conf", os.R_OK) and os.access(instRoot + "/boot/etc/silo.conf", os.R_OK)): diff --git a/booty/x86.py b/booty/x86.py index 535aaab84..0ce86053c 100644 --- a/booty/x86.py +++ b/booty/x86.py @@ -72,10 +72,10 @@ class x86BootloaderInfo(efiBootloaderInfo): syncDataToDisk(bootDev, "/", instRoot) # copy the stage files over into /boot - rhpl.executil.execWithRedirect( "/sbin/grub-install", - ["/sbin/grub-install", "--just-copy"], - stdout = "/dev/tty5", stderr = "/dev/tty5", - root = instRoot) + iutil.execWithRedirect("/sbin/grub-install", + ["/sbin/grub-install", "--just-copy"], + stdout = "/dev/tty5", stderr = "/dev/tty5", + root = instRoot) # really install the bootloader for cmd in cmds: @@ -90,12 +90,12 @@ class x86BootloaderInfo(efiBootloaderInfo): else: syncDataToDisk(bootDev, "/", instRoot) - rhpl.executil.execWithRedirect('/sbin/grub' , - [ "grub", "--batch", "--no-floppy", - "--device-map=/boot/grub/device.map" ], - stdin = p[0], - stdout = "/dev/tty5", stderr = "/dev/tty5", - root = instRoot) + iutil.execWithRedirect('/sbin/grub' , + [ "grub", "--batch", "--no-floppy", + "--device-map=/boot/grub/device.map" ], + stdin = p[0], + stdout = "/dev/tty5", stderr = "/dev/tty5", + root = instRoot) os.close(p[0]) def installGrub(self, instRoot, bootDevs, grubTarget, grubPath, fsset, |