Skip to content

Commit a07c085

Browse files
committed
Use 16KB pages on Android.
1 parent 534a41a commit a07c085

2 files changed

Lines changed: 18 additions & 0 deletions

File tree

CHANGES.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Change Log {#changes}
22

3+
## ? - ?
4+
5+
##### Fixes :wrench:
6+
7+
- The native Android library (`libCesiumForUnityNative.so`) is now built with 16 KB ELF segment alignment, enabling compatibility with Android 15+ devices that use 16 KB memory pages.
8+
39
## v1.23.2 - 2026-05-01
410

511
This release updates [cesium-native](https://github.com/CesiumGS/cesium-native) from v0.59.0 to v0.60.0. See the [changelog](https://github.com/CesiumGS/cesium-native/blob/main/CHANGES.md) for a complete list of changes in cesium-native.

native~/CMakeLists.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,18 @@ if (MSVC)
220220
)
221221
endif()
222222

223+
# Android 15+ devices may use 16 KB memory pages. Support them by aligning
224+
# ELF segments to 16 KB. NDK r28+ does this by default; for older NDK versions
225+
# we add the linker flags explicitly.
226+
if (${CMAKE_SYSTEM_NAME} STREQUAL "Android")
227+
target_link_options(
228+
CesiumForUnityNative
229+
PRIVATE
230+
"-Wl,-z,max-page-size=16384"
231+
"-Wl,-z,common-page-size=16384"
232+
)
233+
endif()
234+
223235
target_compile_definitions(
224236
CesiumForUnityNative
225237
PUBLIC

0 commit comments

Comments
 (0)