On Fri, 9 Oct 2009, Jon Masters wrote:
Folks, I know some of you have recently worked on this, for driver disks (msivak in particular), so I figured I would ask. I trying to programmatically do the equivalent of an rpm2cpio and extracting a specific file using rpm-python. I have figured the basics out (getting the header, etc.) but I wish to avoid what yum and others are forced to do in working out the payload location. I haven't looked at Anaconda's implementation yet, but I'm hoping you've found a better way than implementing what rpm-python already should have done?
Pretty much what yum and createrepo have to do to figure out where the payload is it, afaik. Rpm-python has no way of doing an rpm2cpio internally to extract a file, last time I checked. The python cpio bindings are only partially implemented, however they can read from ascii cpio archives (yum install python-cpio on f11 and rawhide)
so I guess you could do it that way but there is nothing that I know of in simple rpm-python to do it.
You could also ask on the rpm-python list at rpm.org Maybe you could tell me what your end goal is? -sv _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list