diff options
author | Matt Wilson <msw@redhat.com> | 1999-08-16 23:25:10 +0000 |
---|---|---|
committer | Matt Wilson <msw@redhat.com> | 1999-08-16 23:25:10 +0000 |
commit | 7277aabe318f322140195f214c3c4a5b9ef441d0 (patch) | |
tree | d93a001329ade3f1a911ae25ad715e230c9d7369 /todo.py | |
parent | e9db63dfa0ae90131bee831cd0da4f77ed5c3ea3 (diff) | |
download | anaconda-7277aabe318f322140195f214c3c4a5b9ef441d0.tar.gz anaconda-7277aabe318f322140195f214c3c4a5b9ef441d0.tar.xz anaconda-7277aabe318f322140195f214c3c4a5b9ef441d0.zip |
package deps
Diffstat (limited to 'todo.py')
-rw-r--r-- | todo.py | 37 |
1 files changed, 32 insertions, 5 deletions
@@ -653,6 +653,38 @@ class ToDo: out = open (self.instPath + "/etc/conf.modules", "w") out.write (inf.read ()) + def verifyDeps (self): + ts = rpm.TransactionSet() + self.comps['Base'].select (1) + + for p in self.hdList.packages.values (): + if p.selected: + ts.add(p.h, (p.h, p.h[rpm.RPMTAG_NAME])) + else: + ts.add(p.h, (p.h, p.h[rpm.RPMTAG_NAME]), "a") + + ts.order() + deps = ts.depcheck() + rc = [] + if deps: + for ((name, version, release), + (reqname, reqversion), + flags, suggest, sense) in deps: + if sense == rpm.RPMDEP_SENSE_REQUIRES: + if suggest: + (header, sugname) = suggest + else: + sugname = _("no suggestion") + if not (name, sugname) in rc: + rc.append ((name, sugname)) + return rc + else: + return None + + def selectDeps (self, deps): + for (who, dep) in deps: + self.hdList[dep].selected = 1 + def doInstall(self, intf): # make sure we have the header list and comps file self.getHeaderList() @@ -661,11 +693,6 @@ class ToDo: # make sure that all comps that include other comps are # selected (i.e. - recurse down the selected comps and turn # on the children - - for comp in self.comps: - if comp.selected: - comp.select(1) - if self.setupFilesystems: self.ddruid.save () self.makeFilesystems () |