summaryrefslogtreecommitdiff
path: root/libbacktrace/configure
diff options
context:
space:
mode:
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-12 21:24:19 +0000
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-12 21:24:19 +0000
commit686b37720d3ae63c168a65b1895b76ad344962b4 (patch)
tree33eae4f1dfeddbcdd692656a204db81bdd98f92d /libbacktrace/configure
parent925e86094f7ee4aa04dd04cd04f7deb2348b392f (diff)
downloadgcc-686b37720d3ae63c168a65b1895b76ad344962b4.tar.gz
* configure.ac: Check for getexecname.
* fileline.c: #include <errno.h>. Define getexecname if not available. (fileline_initialize): Try to find the executable in a few different ways. * print.c (error_callback): Only print the filename if it came from the backtrace state. * configure, config.h.in: Rebuild. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@193454 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libbacktrace/configure')
-rwxr-xr-xlibbacktrace/configure21
1 files changed, 21 insertions, 0 deletions
diff --git a/libbacktrace/configure b/libbacktrace/configure
index 1f6a97b34ae..2a57c5102f3 100755
--- a/libbacktrace/configure
+++ b/libbacktrace/configure
@@ -12319,6 +12319,27 @@ cat >>confdefs.h <<_ACEOF
_ACEOF
+# Check for getexecname function.
+if test -n "${with_target_subdir}"; then
+ case "${host}" in
+ *-*-solaris2*) have_getexecname=yes ;;
+ *) have_getexecname=no ;;
+ esac
+else
+ ac_fn_c_check_func "$LINENO" "getexecname" "ac_cv_func_getexecname"
+if test "x$ac_cv_func_getexecname" = x""yes; then :
+ have_getexecname=yes
+else
+ have_getexecname=no
+fi
+
+fi
+if test "$have_getexecname" = "yes"; then
+
+$as_echo "#define HAVE_GETEXECNAME 1" >>confdefs.h
+
+fi
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tests can run" >&5
$as_echo_n "checking whether tests can run... " >&6; }
if test "${libbacktrace_cv_sys_native+set}" = set; then :