On Nov 7, 2012 1:25 PM, "Anton Vayvod" <ava...@chromium.org> wrote:
>
> Hi,
>
> I'm interested in reusing Chromium IPC code in a project which should work across all major platforms. I'm thinking about using code from src/ipc/ dir but have a couple of questions.
>
> First, how stand-alone ipc/ code is? What does it use except for base/ maybe?
> Second, why it uses sockets instead of named pipes on Linux (and I guess Mac as well)?
Named UNIX domain sockets are resources that need to be cleaned up after use. By using unnamed sockets, the kernel will clean up for us when we crash. Additionally, we restrict filesystem access for renderers and so named sockets may be inaccessible to them.
Cheers
AGL
>
> And lastly, one of the processes that needs to use IPC is GPL-licensed which I think means it can't be simply linked with Chromium codebase. Any thoughts on my options here?
>
> Thanks,
> Anton.
>
> --
> Chromium Developers mailing list: chromi...@chromium.org
> View archives, change email options, or unsubscribe:
> http://groups.google.com/a/chromium.org/group/chromium-dev
Hi,I'm interested in reusing Chromium IPC code in a project which should work across all major platforms. I'm thinking about using code from src/ipc/ dir but have a couple of questions.First, how stand-alone ipc/ code is? What does it use except for base/ maybe?
Second, why it uses sockets instead of named pipes on Linux (and I guess Mac as well)?And lastly, one of the processes that needs to use IPC is GPL-licensed which I think means it can't be simply linked with Chromium codebase. Any thoughts on my options here?
On Wed, Nov 7, 2012 at 10:24 AM, Anton Vayvod <ava...@chromium.org> wrote:
Hi,I'm interested in reusing Chromium IPC code in a project which should work across all major platforms. I'm thinking about using code from src/ipc/ dir but have a couple of questions.First, how stand-alone ipc/ code is? What does it use except for base/ maybe?According to ipc.gyp:'../base/base.gyp:base','../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',So, base, pretty much (dynamic_annotations is required by base, essentially).
BTW one doesn't really need dynamic_annotations if he's not going to run TSan.
Chromium code rocks as a library.
--
--
However, Chrome's IPCs are fine for their intended purpose of being sent across processes inside a single app. I think the reason a separate system was developed was a timing problem where protocol buffers were not open-sourced yet when Chrome development started.