-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Description
Hi,
Are you have a plans for apt-rpm (altlinux-specific) repositories support?
See https://www.altlinux.org/Ownrepo for reference how to create apt-rpm repositories in altlinux environment
Technically, apt-rpm index is just one file pkglist which is really simple to read via rpm-python binding:
import rpm
with open('pkglist.classic') as f:
hdrs = rpm.readHeaderListFromFD(f.fileno())
for hdr in hdrs:
for tag in hdr.keys():
print(f'{tag} => {hdr[tag]}')
del hdrs
I suppose function writeHeaderListToFD should write similar data to index file back - I see mention of this function in https://fossies.org/linux/misc/old/rpm-5.2.1.tar.gz/rpm-5.2.1/CHANGES but no implementation in /usr/lib64/python3/site-packages/rpm/__init__.py
So, see C implementation of reading/writing pkglist file:
- https://git.altlinux.org/gears/a/apt-repo-tools.git?p=apt-repo-tools.git;a=blob;f=src/pkglist-query.cc
- https://git.altlinux.org/gears/a/apt-repo-tools.git?p=apt-repo-tools.git;a=blob;f=src/genpkglist.cc
Is it possible to implement something like above in mkrepo with own rpm implementation?
Metadata
Metadata
Assignees
Labels
No labels