diff options
author | Sree Harsha Totakura <totakura@in.tum.de> | 2012-10-31 09:15:05 +0000 |
---|---|---|
committer | Sree Harsha Totakura <totakura@in.tum.de> | 2012-10-31 09:15:05 +0000 |
commit | f2ac1a162054f0f7646b35d3a03d623c58a24c20 (patch) | |
tree | 55b60da9bd2080693e6ac4d138bfc7c491fec645 /src/testbed/testbed_api.c | |
parent | 0a0036407218d7f9588d2b6b796b2a6f779bf700 (diff) | |
download | gnunet-f2ac1a162054f0f7646b35d3a03d623c58a24c20.tar.gz gnunet-f2ac1a162054f0f7646b35d3a03d623c58a24c20.zip |
locate helpers in libexec
Diffstat (limited to 'src/testbed/testbed_api.c')
-rw-r--r-- | src/testbed/testbed_api.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/testbed/testbed_api.c b/src/testbed/testbed_api.c index 9696785f3..5bba87c19 100644 --- a/src/testbed/testbed_api.c +++ b/src/testbed/testbed_api.c | |||
@@ -68,13 +68,6 @@ | |||
68 | 68 | ||
69 | 69 | ||
70 | /** | 70 | /** |
71 | * Testbed Helper binary name | ||
72 | */ | ||
73 | #define HELPER_TESTBED_BINARY "gnunet-helper-testbed" | ||
74 | #define HELPER_TESTBED_BINARY_SSH ". ~/.bashrc; gnunet-helper-testbed" | ||
75 | |||
76 | |||
77 | /** | ||
78 | * Handle for controller process | 71 | * Handle for controller process |
79 | */ | 72 | */ |
80 | struct GNUNET_TESTBED_ControllerProc | 73 | struct GNUNET_TESTBED_ControllerProc |
@@ -1464,6 +1457,7 @@ GNUNET_TESTBED_controller_start (const char *controller_ip, | |||
1464 | } | 1457 | } |
1465 | else | 1458 | else |
1466 | { | 1459 | { |
1460 | char *helper_binary_path; | ||
1467 | char *remote_args[10]; | 1461 | char *remote_args[10]; |
1468 | unsigned int argp; | 1462 | unsigned int argp; |
1469 | const char *username; | 1463 | const char *username; |
@@ -1485,13 +1479,17 @@ GNUNET_TESTBED_controller_start (const char *controller_ip, | |||
1485 | remote_args[argp++] = "-o"; | 1479 | remote_args[argp++] = "-o"; |
1486 | remote_args[argp++] = "NoHostAuthenticationForLocalhost=yes"; | 1480 | remote_args[argp++] = "NoHostAuthenticationForLocalhost=yes"; |
1487 | remote_args[argp++] = cp->dst; | 1481 | remote_args[argp++] = cp->dst; |
1488 | // FIXME: lib/gnunet/libexec/-prefix missing here!!! | 1482 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_string (cfg, "testbed", |
1489 | remote_args[argp++] = HELPER_TESTBED_BINARY_SSH; | 1483 | "HELPER_BINARY_PATH", |
1484 | &helper_binary_path)) | ||
1485 | helper_binary_path = GNUNET_OS_get_libexec_binary_path (HELPER_TESTBED_BINARY); | ||
1486 | remote_args[argp++] = helper_binary_path; | ||
1490 | remote_args[argp++] = NULL; | 1487 | remote_args[argp++] = NULL; |
1491 | GNUNET_assert (argp == 10); | 1488 | GNUNET_assert (argp == 10); |
1492 | cp->helper = | 1489 | cp->helper = |
1493 | GNUNET_HELPER_start (GNUNET_NO, "ssh", remote_args, &helper_mst, | 1490 | GNUNET_HELPER_start (GNUNET_NO, "ssh", remote_args, &helper_mst, |
1494 | &helper_exp_cb, cp); | 1491 | &helper_exp_cb, cp); |
1492 | GNUNET_free (helper_binary_path); | ||
1495 | } | 1493 | } |
1496 | if (NULL == cp->helper) | 1494 | if (NULL == cp->helper) |
1497 | { | 1495 | { |