[OE-core] [PATCH 00/45] Move recipes to use Python 3 whenever possible

Mark Hatle mark.hatle at windriver.com
Thu May 26 13:39:08 UTC 2016


On 5/25/16 8:01 AM, alexander.kanavin at linux.intel.com wrote:
>>> Consequently, rpm's python bindings (required by smartpm) stay at python
>>> 2 as well
>>> for now, even tough python 3 seems to be supported.
>>
>> Is there a porting guide or similar that can used to help identify what
>> types of
>> changes are needed.  I am not at all familiar with what python 3 needs
>> specifically, but I do expect we will need to port these items.
> 
> Of course, there's a ton of such guides on the net. Here's the official one:
> https://docs.python.org/3/howto/pyporting.html
> 
>> The yum version of createrepo will not work.  We need to port forward the
>> component as appropriate -- or modify smartpm to use a newer version --
>> assuming
>> we can add missing pieces, as necessary.  (key is smartpm and createrepo
>> need to
>> be kept in sync.)
> 
> Can you say why it won't work, specifically, if we also replace smartpm
> with yum or dnf at the same time? The only alternative I see is that we
> have to fork the old version of createrepo and the abandoned upstream of
> smartpm, port them to Python 3, and maintain them going forward - not a
> light undertaking.

The interchange format of the newer createrepo is very different then the older
format the smartpm uses.  Thus they have to be kept in sync.  The new format
also does not have the extensions we added for the recommended package syntax.

createrepo is very small, and it's not YUM dependent.  It simply reads the
metadata (via the rpm interface) and dumps out data in an XML format.. then does
a few more things as well.  So porting the existing one forward shouldn't be
difficult.  It's just not clear at this point what the best behavior will be to
do.. port createrepo forward -- or update smartpm to support the newer format
(with appropriate extensions.)

--Mark

>> Please create one (or three) defects and assign them to me for smartpm,
>> createrepo, and rpm python3 support.  (I doubt I'll be the one doing the
>> work,
>> but I'll do my best to find someone to do the work.)
> 
> Yes, I'll do that now.
> 
>>> 5) LSB spec is implicitly requiring Python 2 (via requirement for
>>> '/usr/bin/python').
>>
>> I expect the LSB will require python 2 for a while.  So we will need to
>> continue
>> to ensure that python 2 works, as well as python3.
> 
> Of course, Python 2 will be supported by upstream at least until 2020, and
> so it'll be provided by oe-core at least until then. 2.7.12 should appear
> soon.
> 
> Alex
> 




More information about the Openembedded-core mailing list