Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,11 @@ Schema:
```

`android_abis` lists the ABIs `package-for-dart.sh` builds for this minor —
64-bit first, then `armeabi-v7a` if the minor still supports 32-bit Android.
3.12 carries all three; 3.13+ are 64-bit-only ([PEP 738](https://peps.python.org/pep-0738/)).
64-bit (`arm64-v8a`, `x86_64`) plus 32-bit `armeabi-v7a`. [PEP 738](https://peps.python.org/pep-0738/)
makes 64-bit Android the *tested* Tier-3 configuration, but CPython's official
`Android/android.py` still builds 32-bit ARM (it's in its supported `HOSTS`), so
all three minors carry `armeabi-v7a`. Drop an ABI from a minor's list to stop
building it.

The committed file omits `release`; the publish step injects it.

Expand Down
5 changes: 2 additions & 3 deletions android/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ To build all ABIs:
./build-all.sh 3.13.12
```

ABI support:
* Python 3.12: `arm64-v8a`, `armeabi-v7a`, `x86_64`
* Python 3.13+: `arm64-v8a`, `x86_64`
ABI support (all minors): `arm64-v8a`, `x86_64`, `armeabi-v7a`. The exact set
built per minor is driven by `android_abis` in the top-level `manifest.json`.

## Credits

Expand Down
16 changes: 10 additions & 6 deletions android/build-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,18 @@ python_version=${1:?}
read version_major version_minor < <(
echo "$python_version" | sed -E 's/^([0-9]+)\.([0-9]+).*/\1 \2/'
)
version_int=$((version_major * 100 + version_minor))
short="$version_major.$version_minor"

if [ $version_int -ge 313 ]; then
abis="arm64-v8a x86_64"
else
abis="arm64-v8a armeabi-v7a x86_64"
# ABIs come from the manifest (`pythons.<short>.android_abis`), the same source
# the CI packaging step reads — keep them in lockstep so a minor's ABI set is
# edited in exactly one place.
manifest="$(dirname "$(realpath "$0")")/../manifest.json"
abis=$(jq -r --arg s "$short" '.pythons[$s].android_abis[]' "$manifest")
if [ -z "$abis" ]; then
echo "manifest.json has no .pythons[\"$short\"].android_abis" >&2
exit 1
fi

for abi in $abis; do
bash ./build.sh $python_version $abi
bash ./build.sh "$python_version" "$abi"
done
4 changes: 2 additions & 2 deletions android/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -148,10 +148,10 @@ if [ $version_int -le 312 ]; then
sed -i -e "s/_PYTHON_HOST_PLATFORM=.*/_PYTHON_HOST_PLATFORM=android-$api_level-$abi/" $PREFIX/lib/python$version_short/config-$version_short/Makefile
else
case "$abi" in
arm64-v8a|x86_64)
arm64-v8a|x86_64|armeabi-v7a)
;;
*)
echo "Python $version_short official Android build supports only: arm64-v8a, x86_64"
echo "Python $version_short official Android build supports only: arm64-v8a, x86_64, armeabi-v7a"
exit 1
;;
esac
Expand Down
4 changes: 2 additions & 2 deletions manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
"standalone_release_date": "20260623",
"pyodide_version": "0.29.4",
"pyodide_platform_tag": "pyemscripten-2025.0-wasm32",
"android_abis": ["arm64-v8a", "x86_64"],
"android_abis": ["arm64-v8a", "x86_64", "armeabi-v7a"],
"prerelease": false
},
"3.14": {
"full_version": "3.14.6",
"standalone_release_date": "20260623",
"pyodide_version": "314.0.1",
"pyodide_platform_tag": "pyemscripten-2026.0-wasm32",
"android_abis": ["arm64-v8a", "x86_64"],
"android_abis": ["arm64-v8a", "x86_64", "armeabi-v7a"],
"prerelease": false
}
}
Expand Down
Loading