ashmem

Crates.ioashmem
lib.rsashmem
version0.1.2
sourcesrc
created_at2021-03-25 21:29:09.18853
updated_at2021-12-23 10:44:20.125922
descriptionRust wrapper around Android's ASharedMemory (ashmem) API
homepage
repositoryhttps://github.com/kinetiknz/ashmem-rs
max_upload_size
id373559
size8,159
Matthew Gregan (kinetiknz)

documentation

README

ashmem-rs

Provides a compatibility interface for Android 8.0's public ASharedMemory API.

Some variant of ashmem has existed in Android as a private API for some time. Originally available only via direct ioctl interface, it later became callable (still private) via ashmem_create_region (et al.) in libcutils.

ASharedMemory is the public API to ashmem made available in Android 8.0 (API level 26). Builds targeting Android 10 (API 29) are no longer permitted to access ashmem via the ioctl interface. This makes life for a portable program difficult - you can't reliably use the old or new interface during this transition period.

ashmem-rs provides a simple wrapper around the ASharedMemory API, directly calling the public API implementation via dynamically loaded libandroid where available, and falling back to the direct ioctl interface elsewhere.

References:

Commit count: 6

cargo fmt