On Sun, Jan 12, 2014 at 11:51:01AM +0100, Johannes Krampf wrote:
Hello SeaBIOS developers,
I've created a new patch which allows me to build SeaBIOS successfully with both Python 2 and Python 3. (Tested with qemu)
Thanks. I broke up your patches to make them easier to discuss (see attached). Can you provide a "Signed-off-by" for them?
Aside from print statements/functions, str/bytes and integer division for Python 2/3 compatibility, I also did some small changes (removing semicolons) to the acpi_* files to reduce the noise from pylint output.
I'm uncomfortable with the as_bytes/as_str change. I wonder if there is a way to avoid all the conversions by changing all the symbols to strings up front, or by just reading/writing the files in ascii mode instead of binary mode.
I was careful not to break the code, but I could not test the readserial script lacking the necessary hardware and would appreciate if someone else could give it a try.
All of my changes should work with Python 2.4 and newer (version in RHEL 5, the oldest supported version). If you require compatibility with older Python versions, please tell me and I will revise the patch.
-Kevin