aboutsummaryrefslogtreecommitdiff
path: root/gdb/configure.ac
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>2011-05-09 21:49:57 +0000
committerDoug Evans <dje@google.com>2011-05-09 21:49:57 +0000
commit478aac75e4114810db639e06a13e15547ec49e3d (patch)
treef9952574ed7f284c1a30ff2052208d9e398fa0fa /gdb/configure.ac
parent673c2bbeab36a7240fc8b85e696fbad249fbf408 (diff)
downloadgdb-478aac75e4114810db639e06a13e15547ec49e3d.zip
gdb-478aac75e4114810db639e06a13e15547ec49e3d.tar.gz
gdb-478aac75e4114810db639e06a13e15547ec49e3d.tar.bz2
* NEWS: Mention --with-iconv-bin.
* configure.ac: New option --with-iconv-bin. * configure: Regenerate. * config.in: Regenerate. * defs.h (relocate_gdb_directory): Declare. * main.c (relocate_gdb_directory): Renamed from relocate_directory, removed progname parameter, and exported. All callers updated. * charset.c (find_charset_names): Use --with-iconv-bin if specified. doc/ * gdb.texinfo (Requirements): Fix typo. Mention --with-iconv-bin.
Diffstat (limited to 'gdb/configure.ac')
-rw-r--r--gdb/configure.ac23
1 files changed, 23 insertions, 0 deletions
diff --git a/gdb/configure.ac b/gdb/configure.ac
index 96e0a7b..a42ce27 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -433,6 +433,29 @@ AC_SEARCH_LIBS(dlgetmodinfo, [dl xpdl])
AM_ICONV
+# GDB may fork/exec the iconv program to get the list of supported character
+# sets. Allow the user to specify where to find it.
+# There are several factors affecting the choice of option name:
+# - There is already --with-libiconv-prefix but we can't use it, it specifies
+# the build-time location of libiconv files.
+# - The program we need to find is iconv, which comes with glibc. The user
+# doesn't necessarily have libiconv installed. Therefore naming this
+# --with-libiconv-foo feels wrong.
+# - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
+# defined to work on directories not files (though it really doesn't know
+# the difference).
+# - Calling this --with-iconv-prefix is perceived to cause too much confusion
+# with --with-libiconv-prefix.
+# Putting these together is why the option name is --with-iconv-bin.
+
+AC_ARG_WITH(iconv-bin,
+AS_HELP_STRING([--with-iconv-bin=PATH], [specify where to find the iconv program]),
+[iconv_bin="${withval}"
+ AC_DEFINE_UNQUOTED([ICONV_BIN], ["${iconv_bin}"],
+ [Path of directory of iconv program.])
+ GDB_AC_DEFINE_RELOCATABLE(ICONV_BIN, iconv, ${iconv_bin})
+])
+
# On alpha-osf, it appears that libtermcap and libcurses are not compatible.
# There is a very specific comment in /usr/include/curses.h explaining that
# termcap routines built into libcurses must not be used.