aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2002-02-23 21:54:25 +0000
committerAndrew Cagney <cagney@redhat.com>2002-02-23 21:54:25 +0000
commit27aac7ff48e06d83f102a463685bc61469c8265b (patch)
treecbe9eb2809627cded0e37797cb3c1b693a498abd
parent65a6e0eee547e96f0d3d949faebb8cac90e01b0c (diff)
downloadgdb-27aac7ff48e06d83f102a463685bc61469c8265b.zip
gdb-27aac7ff48e06d83f102a463685bc61469c8265b.tar.gz
gdb-27aac7ff48e06d83f102a463685bc61469c8265b.tar.bz2
* configure.in: (AC_CHECK_FUNCS) Added test for
canonicalize_file_name Regenerated. * config.in, configure: Regenerated. * utils.c: (gdb_realpath) If HAVE_CANONICALIZE_FILE_NAME is defined use canonicalize_file_name.
-rw-r--r--gdb/ChangeLog10
-rw-r--r--gdb/config.in3
-rwxr-xr-xgdb/configure4
-rw-r--r--gdb/configure.in4
-rw-r--r--gdb/utils.c4
5 files changed, 20 insertions, 5 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 65ae275..3361c1e 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,13 @@
+2002-02-23 Andrew Cagney <ac131313@redhat.com>
+
+ From 2002-02-22 Alfred M. Szmidt <ams@kemisten.nu>:
+
+ * configure.in: (AC_CHECK_FUNCS) Added test for
+ canonicalize_file_name Regenerated.
+ * config.in, configure: Regenerated.
+ * utils.c: (gdb_realpath) If HAVE_CANONICALIZE_FILE_NAME is
+ defined use canonicalize_file_name.
+
2002-02-23 Michael Chastain <mec@shout.net>
* MAINTAINERS: Remove Michael Chastain from "paper trail" list.
diff --git a/gdb/config.in b/gdb/config.in
index c8ac3fa..f2bab55 100644
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -202,6 +202,9 @@
/* Define if you have the bzero function. */
#undef HAVE_BZERO
+/* Define if you have the canonicalize_file_name function. */
+#undef HAVE_CANONICALIZE_FILE_NAME
+
/* Define if you have the dcgettext function. */
#undef HAVE_DCGETTEXT
diff --git a/gdb/configure b/gdb/configure
index 8a9500b..c111aea 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -3582,8 +3582,8 @@ EOF
fi
-for ac_func in bcopy btowc bzero isascii poll realpath sbrk setpgid setpgrp \
- sigaction sigprocmask sigsetmask
+for ac_func in bcopy btowc bzero canonicalize_file_name isascii poll \
+ realpath sbrk setpgid setpgrp sigaction sigprocmask sigsetmask
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:3590: checking for $ac_func" >&5
diff --git a/gdb/configure.in b/gdb/configure.in
index 672f260..cb9e59b 100644
--- a/gdb/configure.in
+++ b/gdb/configure.in
@@ -131,8 +131,8 @@ AC_HEADER_STAT
AC_C_CONST
-AC_CHECK_FUNCS(bcopy btowc bzero isascii poll realpath sbrk setpgid setpgrp \
- sigaction sigprocmask sigsetmask)
+AC_CHECK_FUNCS(bcopy btowc bzero canonicalize_file_name isascii poll \
+ realpath sbrk setpgid setpgrp sigaction sigprocmask sigsetmask )
AC_FUNC_ALLOCA
AC_FUNC_VFORK
dnl AC_FUNC_SETPGRP does not work when cross compiling
diff --git a/gdb/utils.c b/gdb/utils.c
index 627c89e..8646020 100644
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -2526,7 +2526,9 @@ string_to_core_addr (const char *my_string)
char *
gdb_realpath (const char *filename)
{
-#ifdef HAVE_REALPATH
+#ifdef HAVE_CANONICALIZE_FILE_NAME
+ return canonicalize_file_name (filename);
+#elif defined (HAVE_REALPATH)
#if defined (PATH_MAX)
char buf[PATH_MAX];
#elif defined (MAXPATHLEN)