Skip to content

Commit

Permalink
android_jni: Support 16kb page size
Browse files Browse the repository at this point in the history
Add -Wl,-z,max-page-size=16384 linker flag when building the JNI
wrapper to support newly added 16kb page size on Android.

https://developer.android.com/guide/practices/page-sizes#cmake

Fixes issue #2464
  • Loading branch information
vigneshvg committed Nov 19, 2024
1 parent ea21e9b commit 566e2ed
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions android_jni/avifandroidjni/src/main/jni/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,5 @@ set(CPU_FEATURES_DIR "${ANDROID_NDK}/sources/android/cpufeatures")
include_directories(${CPU_FEATURES_DIR})
add_library(cpufeatures STATIC "${CPU_FEATURES_DIR}/cpu-features.c")

target_link_options(avif_android PRIVATE "-Wl,-z,max-page-size=16384")
target_link_libraries(avif_android jnigraphics avif log cpufeatures)

0 comments on commit 566e2ed

Please sign in to comment.