From 40beab42ecdc4e2a79714b54c401feb0fb33b6d0 Mon Sep 17 00:00:00 2001 From: Dries Harnie Date: Sat, 15 May 2010 17:04:47 +0200 Subject: Enable interconnection of emulators This patch adds a -shared-net-id option to the emulator which joins the emulator in a shared network. If the option is given the emulator is started with an additional network interface bound to a multicast socket. This multicast socket emulates a network hub, interconnecting emulators. If the -shared-net-id option is not given, nothing changes. Change-Id: I0ea70a073cdbd34f804161300240fafca34080d0 --- android/help.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'android/help.c') diff --git a/android/help.c b/android/help.c index e8737f5..23a94dd 100644 --- a/android/help.c +++ b/android/help.c @@ -1348,6 +1348,23 @@ help_prop(stralloc_t *out) ); } +static void +help_shared_net_id(stralloc_t* out) +{ + PRINTF( + " Normally, Android instances running in the emulator cannot talk to each other\n" + " directly, because each instance is behind a virtual router. However, sometimes\n" + " it is necessary to test the behaviour of applications if they are directly\n" + " exposed to the network.\n\n" + + " This option instructs the emulator to join a virtual network shared with\n" + " emulators also using this option. The number given is used to construct\n" + " the IP address 10.1.2., which is bound to a second interface on\n" + " the emulator. Each emulator must use a different number.\n\n" + ); +} + + #define help_no_skin NULL #define help_netspeed help_shaper #define help_netdelay help_shaper -- cgit v1.1