Upgrade Android minimum API level from 24 to 28#227
Merged
Conversation
Three changes: 1. Bump Android platform from API 24 to API 28 (CMakeLists.txt and publish.yml). mtmd-helper.cpp includes vendor/sheredom/subprocess.h which calls posix_spawn* / posix_spawn_file_actions_*; these symbols are available in the NDK libc at all API levels but their <spawn.h> declarations are only exposed when __ANDROID_API__ >= 28. API 24 was enough for getifaddrs; API 28 is required to compile mtmd-helper.cpp. Both Android build jobs (CPU-only and OpenCL/Adreno) are updated. 2. Update CMakeLists.txt comment to document why API 28 is needed (__ANDROID_API__ now gates both getifaddrs and posix_spawn*). 3. Add --no-transfer-progress to the four mvn compile steps that were missing it on macOS / Linux native build jobs and to both publish (snapshot + release) deploy steps, eliminating the verbose per-chunk download progress lines from CI logs. Note: The NotJavadoc compile error on macOS and Ubuntu was already fixed by commit 8932fd8 (removing the orphaned duplicate Javadoc block before completeBatch). This commit does not touch that check. https://claude.ai/code/session_01RcJfwgM2cfjd3n5A8JrGqe
posix_spawn* (used by mtmd-helper.cpp via subprocess.h) is only declared in NDK headers when __ANDROID_API__ >= 28, making Android 9.0 Pie the minimum supported version. Add an explicit note to the README [!NOTE] block, the "Importing in Android" section, and a new CLAUDE.md section that mirrors the CUDA version pattern with upgrade instructions. https://claude.ai/code/session_01RcJfwgM2cfjd3n5A8JrGqe
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
posix_spawnfunctions required bymtmd-helper.cpp--no-transfer-progressflag to all Maven invocations in CI workflows for cleaner logsDetails
Android API Level Change:
The minimum required Android API level is increased from 24 to 28 because
mtmd-helper.cpp(part of the upstream llama.cpp multimodal library) includesvendor/sheredom/subprocess.h, which callsposix_spawn,posix_spawnp, andposix_spawn_file_actions_*. These symbols are only declared in Android NDK headers when__ANDROID_API__ >= 28, though the symbols exist inlibc.soat all API levels.Changes made:
add_compile_definitions(__ANDROID_API__=28)(was 24).github/workflows/publish.yml: Updated-DANDROID_PLATFORM=android-28in both Android build jobs (was android-24)Maven Output Cleanup:
Added
--no-transfer-progressflag to Maven commands across all CI workflows (publish.yml, codeql.yml, sonarqube.yml) to suppress verbose dependency download progress output and improve log readability.Test plan
Checklist
CONTRIBUTING.mdandCODE_OF_CONDUCT.mdhttps://claude.ai/code/session_01RcJfwgM2cfjd3n5A8JrGqe