Configuring GDB with autoload directory list

Eli Zaretskii eliz@gnu.org
Sun Oct 9 11:28:00 GMT 2016


I keep around old binaries of GDB, renamed as gdb-VERSION, for testing
purposes.  So I don't like it when a new installation overwrites the
data files of the old one under share/gdb/.  So I configure GDB to use
a version specific directory, as in

   --with-gdb-datadir=d:/usr/share/gdb/7.12

That requires me to augment the auto-load places, because those are
common, not specific to some GDB version.  So I also include these two
options to configure:

  --with-auto-load-dir='$debugdir;$datadir/../auto-load' --with-auto-load-safe-path='$debugdir;$datadir/../auto-load'

Note that I must use the semi-colon in these lists, because this is a
native MS-Windows build of GDB.

The problem is that this somehow doesn't work  The configure script
emits the following messages:

  checking for default auto-load directory... /d/gnu/gdb-7.12/gdb/configure: line 5580: \$datadir/../auto-load: No such file or directory
  $debugdir;$datadir/../auto-load
  checking for default auto-load safe-path... /d/gnu/gdb-7.12/gdb/configure: line 5607: \$datadir/../auto-load: No such file or directory
  $debugdir;$datadir/../auto-load

and the produced gdb/config.h says just this:

  /* Directories from which to load auto-loaded scripts. */
  #define AUTO_LOAD_DIR "$debugdir"

  /* Directories safe to hold auto-loaded files. */
  #define AUTO_LOAD_SAFE_PATH "$debugdir"

What should I do to get it to say this instead:

  /* Directories from which to load auto-loaded scripts. */
  #define AUTO_LOAD_DIR "$debugdir;$datadir/../auto-load"

  /* Directories safe to hold auto-loaded files. */
  #define AUTO_LOAD_SAFE_PATH "$debugdir;$datadir/../auto-load"

?  Is this a bug in GDB or am I doing something wrong?

TIA.



More information about the Gdb mailing list