gh-146450: Ensure Android gradle build uses custom cross-build dir#148319
gh-146450: Ensure Android gradle build uses custom cross-build dir#148319freakboy3742 wants to merge 6 commits intopython:mainfrom
Conversation
|
!buildbot android |
|
🤖 New build scheduled with the buildbot fleet by @freakboy3742 for commit 68ba1d7 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F148319%2Fmerge The command will test the builders whose names match following regular expression: The builders matched are:
|
Android/android.py
Outdated
| # Ensure that CROSS_BUILD_DIR is in the Gradle environment, regardless | ||
| # of whether it was set by environment variable or `--cross-build-dir`. | ||
| env = os.environ.copy() | ||
| env["CROSS_BUILD_DIR"] = CROSS_BUILD_DIR |
There was a problem hiding this comment.
I was going to say that we could avoid duplication by setting this environment variable in main. However, running the app outside of this script isn't actually useful in practice, so I suggest instead deleting the build-testbed command completely.
Android/android.py
Outdated
| make_host, | ||
| build, | ||
| package, | ||
| build_testbed, |
There was a problem hiding this comment.
main accesses context.cross_build_dir unconditionally even though not every command has this option. In pypa/cibuildwheel#2818 I worked around this using getattr, but in fact every command should have this option, because even env calls subdir in some situations. So I suggest moving the add_argument("--cross-build-dir") call to add_parser.
Co-authored-by: Malcolm Smith <smith@chaquo.com>
|
!buildbot android |
|
🤖 New build scheduled with the buildbot fleet by @freakboy3742 for commit 030c9bd 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F148319%2Fmerge The command will test the builders whose names match following regular expression: The builders matched are:
|
#146450 introduced the ability to customise the
cross-builddirectory (to aid with maintaining multiple Python version backports). The build script honors this setting, but doesn't guarantee that the gradle environment will also use the setting.