diff options
Diffstat (limited to 'libgfortran/runtime')
-rw-r--r-- | libgfortran/runtime/compile_options.c | 4 | ||||
-rw-r--r-- | libgfortran/runtime/main.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/libgfortran/runtime/compile_options.c b/libgfortran/runtime/compile_options.c index 94e1f60..8e0a3fe 100644 --- a/libgfortran/runtime/compile_options.c +++ b/libgfortran/runtime/compile_options.c @@ -108,8 +108,8 @@ set_options (int num, int options[]) /* If backtrace is required, we set signal handlers on most common signals. */ -#if defined(HAVE_SIGNAL_H) && (defined(SIGSEGV) || defined(SIGBUS) \ - || defined(SIGILL) || defined(SIGFPE)) +#if defined(HAVE_SIGNAL) && (defined(SIGSEGV) || defined(SIGBUS) \ + || defined(SIGILL) || defined(SIGFPE)) if (compile_options.backtrace) { #if defined(SIGSEGV) diff --git a/libgfortran/runtime/main.c b/libgfortran/runtime/main.c index be12c59..86777d9 100644 --- a/libgfortran/runtime/main.c +++ b/libgfortran/runtime/main.c @@ -120,7 +120,11 @@ store_exe_path (const char * argv0) } memset (buf, 0, sizeof (buf)); +#ifdef HAVE_GETCWD cwd = getcwd (buf, sizeof (buf)); +#else + cwd = ""; +#endif /* exe_path will be cwd + "/" + argv[0] + "\0" */ path = malloc (strlen (cwd) + 1 + strlen (argv0) + 1); |