Skip to content

autobuild-run: python3 compat and misc improvements

André Erdmann buildroot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest13 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/13autobuild-run, python3: print is a functionscripts/autobuild-run+8 -60 replies
2/13autobuild-run, python3: urllib.request<>urllib2scripts/autobuild-run+10 -40 replies
3/13autobuild-run, python3: bytes<>str, decode()scripts/autobuild-run+16 -30 replies
4/13autobuild-run, python3: configparser<>ConfigParserscripts/autobuild-run+3 -20 replies
5/13autobuild-run: remove unneeded varsscripts/autobuild-run+1 -40 replies
6/13autobuild-run: explicitly close web file handlesscripts/autobuild-run+9 -60 replies
7/13autobuild-run: get host arch oncescripts/autobuild-run+5 -30 replies
8/13autobuild-run: sort imports alphabeticallyscripts/autobuild-run+6 -60 replies
9/13autobuild-run: unify "which <prog>" codescripts/autobuild-run+13 -170 replies
10/13autobuild-run: use a built-in has_prog() implementationscripts/autobuild-run+14 -30 replies
11/13autobuild-run: move check_requirements() to SystemInfoscripts/autobuild-run+72 -480 replies
12/13autobuild-run: encapsulate subprocess callsscripts/autobuild-run+46 -410 replies
13/13autobuild-run: set locale to en_US or Cscripts/autobuild-run+57 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [Buildroot] [PATCH 00/13] autobuild-run: python3 compat and misc improvements

Patches 1-4 make autobuild-run compatible with both python >=2.6 and 3.

Patches 5-9 are minor enhancements (mostly cleanup).

Patches 10- are more invasive:
* move the check_requirements() logic to the SystemInfo class
* control environment(->locale), std{in,out,err} of all called commands

Tested w/ python2.7 and python3.4, but not python2.6 (it should work, though).

This changeset should be mostly compatible with the
"autobuild-run improvements" patchset from Thomas De Schampheleire, except for:

* autobuild-run: extend TODO list

* implements "Integrate method check-requirements with the SysInfo class, distinghuishing between required and optional dependencies.", so this item can be removed from the TODO list

* autobuild-run: check-requirements does not need to know the login details

* dep on "curl" gets set in main()

* autobuild-run: set LC_ALL=C to not use locale settings of host machine

* SystemInfo maintains its own env dict and passes it to subprocess.call()
* ^ tries to find a "comparable" locale: either en_US[.UTF-8] or C (My experience is that some python (build) scripts fail if the locale is not *.utf-8.)
* remove all LANG, LC_* vars from the env if a "comparable" locale is found and set LANG=<locale>

Andr? Erdmann (13):
autobuild-run, python3: print is a function autobuild-run, python3: urllib.request<>urllib2 autobuild-run, python3: bytes<>str, decode() autobuild-run, python3: configparser<>ConfigParser
autobuild-run: remove unneeded vars
autobuild-run: explicitly close web file handles
autobuild-run: get host arch once
autobuild-run: sort imports alphabetically
autobuild-run: unify "which <prog>" code
autobuild-run: use a built-in has_prog() implementation
autobuild-run: move check_requirements() to SystemInfo
autobuild-run: encapsulate subprocess calls
autobuild-run: set locale to en_US or C

 scripts/autobuild-run | 321 ++++++++++++++++++++++++++++++++++----------------
 1 file changed, 218 insertions(+), 103 deletions(-)
Signature · 1 line
2.3.0