Skip to content

Package Android dependencies installed by Briefcase - #134

Open
kattni wants to merge 6 commits into
beeware:mainfrom
kattni:codex/preinstalled-android-dependencies
Open

kattni wants to merge 6 commits into
beeware:mainfrom
kattni:codex/preinstalled-android-dependencies

Conversation

@kattni

@kattni kattni commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Package Briefcase-installed dependency directories with Chaquopy, skipping its pip installer for every build variant. Use the 64-bit ABIs, plus 32-bit ARM on Python 3.11, and bump template compatibility to 0.4.7.

Companion to Briefcase PR #3099. The paired change depends on xbuild PR #119 and xbuild PR #120.

Validation: three template rendering cases, pre-commit checks, and Python 3.11/3.12 APK builds passed.

briefcase-repo: https://github.com/kattni/briefcase
briefcase-ref: codex/android-xbuild-dependencies

PR Checklist:

  • I will abide by the BeeWare Code of Conduct
  • I have read and have followed the CONTRIBUTING.md file
  • This PR was generated or assisted using an AI tool

Assisted-by: OpenAI Codex (GPT-6), Claude Code (Claude Opus 5.5)

{% else %}
// For this Python version, only 64-bit ABIs are available.
// Briefcase's xbuild environments support the 64-bit ABIs.
abiFilters "arm64-v8a", "x86_64"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nobody wants 32-bit Android to disappear as much as me, but based on the discussion in chaquo/chaquopy#1476, I'd prefer not to remove it just yet.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Restored in 632d0f4 for Python 3.11, which is the last version Chaquopy publishes for 32-bit ARM. Newer versions get only the 64-bit ABIs. x86 is still removed.

afterEvaluate {
tasks.withType(com.chaquo.python.TaskBuilder.ReqsTask).configureEach {
enabled = false
outputDir.set(layout.projectDirectory.dir("app_packages"))

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than depending on Chaquopy's undocumented internals, I'd be open to adding a public API for this. But first we need to deal with the Windows compatibility issue in beeware/briefcase#3099, because that might make this whole approach impossible.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Windows problem is fixed in beeware/xbuild#119, which is now merged, so this approach works on Windows. I'd be happy to move to a public API if you add one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants