Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8219437
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T13:09:38+00:00 2026-06-07T13:09:38+00:00

Here I want to use System IPCs methods like <sys/msg.h> /* SysV message queues

  • 0

Here I want to use System IPCs methods like

  <sys/msg.h>   /* SysV message queues */
  <sys/ipc.h>   /* General IPC definitions */

Here my android NDK code is in C language and I used message queue IPC mechanism for communication for other C application.

So please Let me know is there any way to achieve this IPC goal?
How can I implement this IPC mechanism in android NDK code?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T13:09:41+00:00Added an answer on June 7, 2026 at 1:09 pm

    One year ago I wrote a survey about this topic. Here is a part of it:

    2 Unix IPC mechanisms

    Unix IPC mechanisms include:

    • Unix signals.
    • Unix pipes.
    • Unix domain sockets.

    At the same time Unix System-V IPC mechanisms are not included in Android.
    Bionic intentionally does not provide support for System-V IPCs mechanisms, like the
    ones provided by semget(), shmget(), msgget(). The reason for this is to avoid denial-
    of-service [11].

    2.1 Unix signals

    One of the best explanations how unix signals work we can find in wikipedia: “A
    signal is a limited form of inter-process communication used in Unix, Unix-like, and
    other POSIX-compliant operating systems. Essentially it is an asynchronous notifica-
    tion sent to a process in order to notify it of an event that occurred. When a signal is
    sent to a process, the operating system interrupts the process’s normal flow of execu-
    tion. Execution can be interrupted during any non-atomic instruction. If the process has
    previously registered a signal handler, that routine is executed. Otherwise the default
    signal handler is executed.”
    It seems that unix signals are rearly used in Android programming. Moreover,
    some signals have been disabled in debug mode. However, it is a possible IPC
    mechanism.

    2.2 Unix pipes

    Pipe is a communication mechanism that allows to connect directly the output stream
    of one process with the input stread of another process. There are two types of unix
    pipes: named pipes and unnamed pipes. It seems that in Android programming only
    named pipes are used. In this case two processes interact using a special file that
    connects the output and input. It should be mentioned that pipe is one-direction way
    of communication, i.e. one process is always reader and the second is always writer.
    The communication file has to be created on Linux filesystem, because sdcard’s FAT32
    does not allow to create pipe. Here is an example how a named unix pipe can be created
    and used in Android (In Russian). The source code for this example can be found here.

    2.3 Unix domain sockets

    Unix domain sockets, on the contrary of unix pipes, allow to tranfer information in
    both ways: from server to client and from client to server. Unix domain sockets
    and unix pipes use file system as address name space. That means that server and
    client use special file to establish communication. Considering Android there are two
    classes that are used to program unix domain sockets: LocalServerSocket and
    LocalSocket. All the implementation can be built around these two classes and it is
    not required to use native code to make a unix domain socket. A simple example how
    to use unix domain sockets is shown here.

    [11] Android ndk documentation. NDK documentation for android-ndk-r6b

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

hello i want to make system website like yahoo messenger using PHP. here the
I want to use conditional css in my datatable. Here is my code. <ui:repeat
I want to use a global variable in inline assembly. asm( LDR R0,g_TsInitStackPointerAddress); Here
i want to use the listview flicker"less" control found here Link directly in my
The method in question that I want to use is gem and sourced here
I want a second Activity to use the DropboxAPI object (mApi here) and invoke
All Here i want to run .sh file via system call in android NDK.
I want to use the System.ComponentModel.DataAnnotations assembly to validate arguments (mapped to properties) for
I want to use the System.Windows.Controls.DocumentViewer to view a FixedDocument I created from a
I want to use Javascript Alert function in my ASP.NET page. For example like

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.