How to support the 16KB page size of Android 15
Hello, Team Have you researched how to support the 16KB page size of Android 15 How to make Android WebRTC support the 16KB page size of Android 15
I have tested, v125.6422.04 already supports 16KB page size of Android 15.
WebRTC has supported 16KB page size since M121.
The following link is the commit with the fix.
- https://chromium.googlesource.com/chromium/src/build/+/8918c32e85c10226c37806fde56f9d5c4dba11f3%5E%21
Good afternoon @davidliu, @cloudwebrtc ! I would really appreciate your help on this π Is there any possibility to have 16Kb page size support to meet Google requirements? Here is info from google about it:
Starting November 1st, 2025, all new apps and updates to existing apps submitted to Google Play and targeting Android 15+ devices must support 16 KB page sizes on 64-bit devices.
Source Android | Set Android userspace to 16 KB Developer Android | Support 16 KB page sizes
Thank you!
@DanyloOliinykSSG it already supports 16KB page size.
@davidliu unfortunately looks like 137.7151.01 still have some issues with 16 Kb page size alignment π
I've added this dependency into a sample project (i can share it with you if needed):
implementation 'io.github.webrtc-sdk:android-prefixed:137.7151.01'
Then i've run script provided by Google to verify Android app has all *.so files aligned correctly. Here's script output:
./check_elf_alignment.sh app-release.apk
Recursively analyzing app-release.apk
NOTICE: Zip alignment check requires build-tools version 35.0.0-rc3 or higher.
You can install the latest build-tools by running the below command
and updating your $PATH:
sdkmanager "build-tools;35.0.0-rc3"
=== ELF alignment ===
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/armeabi-v7a/liblkjingle_peerconnection_so.so: \e[31mUNALIGNED\e[0m (2**12)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/armeabi-v7a/libandroidx.graphics.path.so: \e[32mALIGNED\e[0m (2**14)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/x86/liblkjingle_peerconnection_so.so: \e[31mUNALIGNED\e[0m (2**12)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/x86/libandroidx.graphics.path.so: \e[32mALIGNED\e[0m (2**14)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/arm64-v8a/liblkjingle_peerconnection_so.so: \e[32mALIGNED\e[0m (2**14)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/arm64-v8a/libandroidx.graphics.path.so: \e[32mALIGNED\e[0m (2**14)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/x86_64/liblkjingle_peerconnection_so.so: \e[32mALIGNED\e[0m (2**14)
/var/folders/dl/v2fx13714qq6stp0ypqjsxk80000gq/T/app-release_out_XXXXX.2Cd3sRuy6q/lib/x86_64/libandroidx.graphics.path.so: \e[32mALIGNED\e[0m (2**14)
\e[31mFound 2 unaligned libs (only arm64-v8a/x86_64 libs need to be aligned).\e[0m
Please, note the UNALIGNED x86/liblkjingle_peerconnection_so.so and armeabi-v7a/liblkjingle_peerconnection_so.so
Am i missing something? Thank you!
@DanyloOliinykSSG As the script mentions, only arm64-v8a/x86_64 libs need to be aligned. The libs you pointed at are not for 64-bit platforms and thus are not required to be aligned.
@davidliu thank you for pointing that out! Looks like everything is fine then π Have a nice day π
To support the 16KB page size, I changed the dependency library from org.webrtc:google-webrtc:1.0.30039 to io.github.webrtc-sdk:android:137.7151.03. I noticed that after the voice call ended, the microphone still shows "In Use"γIt didn't happen before γI have already called AudioTrack.dispose(), do I need to call any other methods?