[U-Boot] python3 support for pylibfdt

Peter Robinson pbrobinson at gmail.com
Fri Jun 28 12:38:01 UTC 2019


> > > > With the EOL of python2 soon I've been looking at the Fedora U-Boot
> > > > builds to see what it would take to move over to python3. There's a
> > > > couple of issues building the bundled pylibfdt, the first is the
> > > > Makefile hard codes python2, the second is that the generated
> > > > libfdt_wrap.c doesn't seem to find the python3 version of Python.h
> > > > (errors below).
> > > >
> > > > It seems upstream now supports building pylibfdt with dtc 1.5.0 but I
> > > > couldn't quite work out how this fits into the U-Boot bundled version.
> > > > Is there plans to be able to support pylibfdt with python3?
> > >
> > > Sounds like we need to run the normal kernel script to re-sync with
> > > upstream?  Thanks!
> >
> > Seems reasonable, I'll keep an eye out for a patch series to test,
> > it's quite straight forward to test from my PoV.
>
> It won't be any time soon, sadly.  Updating to the same dtc in the
> kernel (so just v1.4.7+) causes both massive amount of new device tree
> warnings as well as several fail to link due to size growth problems.

I'm guessing the size problem is due to an increase in size of where
libfdt is linked in and not due to pylibfdt. Would it make sense to
have a feature branch with the rebase to make it easier to test/fix
the issues? And rebasing some DT to the current kernel versions should
fix up a bunch of the DT problems?

Fedora, as are many other distros, is actively retiring python2 due to
it's upcoming EOL ~ 6 months from now. I've had to already rescue a
couple of python2 packages to keep U-Boot building, there's an
intention to actively remove python2 in Fedora 32 (scheduled for May
2020) which means anything post U-Boot 2019.10 (the version we're
aiming for in F-31) will start to cause me big problems.

Maybe we could add this to migration plans like any of the DM subsytems?

Peter


More information about the U-Boot mailing list