Re: [edk2-devel] RFC: Replace FMMT Tool from C to Python Version


Bob Feng
 

Marvin,

The PyGen*** tools I mentioned below are not implemented yet. But we want to convert the BaseTools C tools to python tools so we can move all basetools from edk2 repo to edk2-basetools repo.

For the edk2-basetools repo, please refer to the discussion https://edk2.groups.io/g/devel/topic/73069134#57482

Thanks,
Bob

-----Original Message-----
From: rfc@edk2.groups.io <rfc@edk2.groups.io> On Behalf Of Marvin Häuser
Sent: Friday, October 29, 2021 9:27 PM
To: devel@edk2.groups.io; Feng, Bob C <bob.c.feng@...>; gaoliming@...; Chen, Christine <yuwei.chen@...>; rfc@edk2.groups.io
Cc: Kinney, Michael D <michael.d.kinney@...>
Subject: Re: [edk2-rfc] [edk2-devel] RFC: Replace FMMT Tool from C to Python Version

Good day,

Is there any information available on PyGenFv? It also handles ELF to PE conversion (who knows why...), is that planned to be ported to Python as well? For Project Amaranth, we are currently implementing a tool to replace the ELF to PE conversion (among other things) and decided to write it in C to leverage the existing EDK II libraries for PE and ELF parsing, rather than re-implementing parsing in a different language.
We'd like to stay compatible with upstream EDK II for as long as possible, and plan to send patches for a tool proposal whenever it is ready (do not expect it before mid next year, if at all).

Best regards,
Marvin

On 29.10.21 12:43, Bob Feng wrote:

Liming,

Correct. PyFMMT does not depend on GenSec, GenFfs and GenFv.  Yes. the
future PyGenSec, PyGenFfs and PyGenFv can reuse code from PyFMMT.

Thanks,

Bob

*From:* devel@edk2.groups.io <devel@edk2.groups.io> *On Behalf Of
*gaoliming
*Sent:* Friday, October 29, 2021 10:16 AM
*To:* Chen, Christine <yuwei.chen@...>; devel@edk2.groups.io;
rfc@edk2.groups.io
*Cc:* Feng, Bob C <bob.c.feng@...>; Kinney, Michael D
<michael.d.kinney@...>
*Subject:* 回复: [edk2-devel] RFC: Replace FMMT Tool from C to Python
Version

Christine:

 This is a good news. Thanks for your great work. With this change,
FMMT doesn’t depend on GenSec, GenFfs and GenFv C tool. Right? If yes,
can those logic be reused to replace GenSec, GenFfs and GenFv C tools?

Thanks

Liming

*发件人**:*Chen, Christine <yuwei.chen@...>
*发送时间:* 2021年10月29日 8:33
*收件人:* devel@edk2.groups.io; rfc@edk2.groups.io
*抄送:* Feng, Bob C <bob.c.feng@...>; Kinney, Michael D
<michael.d.kinney@...>; Liming Gao <gaoliming@...>
*主题:* [edk2-devel] RFC: Replace FMMT Tool from C to Python Version

Hi everyone,

I would like to propose the new FMMT Python tool, which is used to
replace the origin C version tool.

Currently the FMMT C tool is saved in edk2-staging repo, but its
quality and coding style can’t meet the Edk2 quality, which is hard to
maintain (Hard/Duplicate Code; Regression bugs; Restrict usage).

The new Python version keeps same functions with origin C version. It
has higher quality and better coding style, and it is much easier to
extend new functions and to maintain.

You can get the FMMT Python tool through below link.

https://github.com/tianocore/edk2-staging/tree/PyFMMT
<https://github.com/tianocore/edk2-staging/tree/PyFMMT>

If you are interested in that, pls have a try.

Looking forward to your feedback~

Thanks,

Christine (Yuwei)

Join rfc@edk2.groups.io to automatically receive all group messages.