#include "opal/util/opal_environ.h"
#include "opal/runtime/opal.h"
+#ifndef MAXPATHLEN /* Hurd */
+#define MAXPATHLEN 65535
+#endif
+
+#ifndef PATH_MAX /* Hurd */
+#define PATH_MAX 65535
+#endif
+
/*
* local variables
*/
/* Setup the signals to catch */
memset(&act, 0, sizeof(act));
+#ifdef SA_SIGINFO
act.sa_sigaction = show_stackframe;
act.sa_flags = SA_SIGINFO;
+#else
+ act.sa_handler = show_stackframe_handler;
+#endif
#ifdef SA_ONESHOT
act.sa_flags |= SA_ONESHOT;
#else
orte_app_context_t *app;
orte_proc_t *child=NULL;
int rc=ORTE_SUCCESS;
- char basedir[MAXPATHLEN];
+#if !defined(MAXPATHLEN) && defined(__GLIBC__)
+ char *basedir=NULL;
+#else
+ char basedir[MAXPATHLEN];
+#endif
int j, idx;
int total_num_local_procs = 0;
orte_odls_launch_local_t *caddy = (orte_odls_launch_local_t*)cbdata;
* bouncing around as we execute various apps, but we will always return
* to this place as our default directory
*/
+#if !defined(MAXPATHLEN) && defined(__GLIBC__)
+ basedir = get_current_dir_name();
+#else
getcwd(basedir, sizeof(basedir));
+#endif
/* find the jobdat for this job */
if (NULL == (jobdat = orte_get_job_data_object(job))) {
int rc;
orte_app_context_t *app;
orte_job_t *jobdat;
- char basedir[MAXPATHLEN];
+#if !defined(MAXPATHLEN) && defined(__GLIBC__)
+ char *basedir=NULL;
+ char *dir=NULL;
+#else
+ char basedir[MAXPATHLEN];
+#endif
char *wdir = NULL;
orte_odls_spawn_caddy_t *cd;
opal_event_base_t *evb;
* bouncing around as we execute this app, but we will always return
* to this place as our default directory
*/
+#if !defined(MAXPATHLEN) && defined(__GLIBC__)
+ basedir = get_current_dir_name();
+#else
getcwd(basedir, sizeof(basedir));
+#endif
/* find this child's jobdat */
if (NULL == (jobdat = orte_get_job_data_object(child->name.jobid))) {