Why the function `rpmUtils.arch.getArchList()` returns i386, i486, etc. arches?
samuel-phan opened this issue ยท 3 comments
I was looking for a way to download all the dependencies of an RPM. I found this link:
telling to do this:
repotrack -a x86_64 -p /repos/Packages [packages]
The author claims that there is a bug: indeed, this command will download RPMs with arch x86_64, but also i*86 arches.
Here is the list of arch returned by the function rpmUtils.arch.getArchList()
for the given option -a x86_64
:
['x86_64', 'athlon', 'i686', 'i586', 'i486', 'i386', 'noarch']
Is it a bug, or is there a real reason to download also all the packages with those different arches?
Here is the source of the function rpmUtils.arch.getArchList()
:
https://github.com/rpm-software-management/yum/blob/master/rpmUtils/arch.py#L213-L231
Thanks,
Hello,
Not sure if you still have this question.
Would try to answer. As per defination getArchList method would return arch compatible to arch you have provided, as per that I can see that it list all of below arch, as per method
`def getArchList(thisarch=None):
this returns a list of archs that are compatible with arch given`
# amd64
"x86_64": "athlon",
"amd64": "x86_64",
"ia32e": "x86_64",
"athlon": "i686",
"i686": "i586",
"i586": "i486",
"i486": "i386",
"i386": "noarch",
Thanks @upadhyeammit , it answers my question.
That really doesn't answer the question of why repotrack should be downloading compatible architectures, rather than just the architecture given (plus noarch). That is answered here: https://bugzilla.redhat.com/show_bug.cgi?id=1150115