Skip to content

Welpyes/libshmemu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

libshmemu

A lightweight POSIX shared memory (shm_open, shm_unlink) emulation library for Android/Bionic (Termux).

Overview

The Android Bionic libc does not provide shm_open and shm_unlink. This library provides a shim that emulates these calls by using regular files in the directory specified by the TMPDIR environment variable (defaulting to /data/data/com.termux/files/usr/tmp).

Building

make

This will produce libshmemu.a and libshmemu.so.

Installation

make install

Usage

In Your Project

  1. Add -I/path/to/libshmemu to your include flags.
  2. Add -L/path/to/libshmemu -lshmemu to your linker flags.
  3. Include the header or use -include shmemu.h in your compiler flags to avoid modifying source code.

Example config.mk snippet:

INCS += -I./libshmemu
LIBS += -L./libshmemu -lshmemu
CPPFLAGS += -include shmemu.h

About

Lightweight Posix shm_open and shm_unlink emulation library for Android/Bionic

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors