Now (thanks to the last few commits) all extension languages are
fully initialised in their finish_initialization method, this commit
delays the call to this method until after the early initialization
files have been processed.
Right now there's no benefit from doing this, but in a later commit I
plan to add new options for Python that will control how Python is
initialized.
With this commit in place, my next commits will allow the user to add
options to their early initialization file and alter how Python starts
up.
There should be no user visible changes after this commit.
gdb/ChangeLog:
* main.c (captured_main_1): Add a call to
finish_ext_lang_initialization.
* top.c (gdb_init): Remove call to finish_ext_lang_initialization.
+2021-04-28 Andrew Burgess <andrew.burgess@embecosm.com>
+
+ * main.c (captured_main_1): Add a call to
+ finish_ext_lang_initialization.
+ * top.c (gdb_init): Remove call to finish_ext_lang_initialization.
+
2021-04-28 Andrew Burgess <andrew.burgess@embecosm.com>
* guile/guile.c (gdbscm_set_backtrace): Add declaration.
execute_cmdargs (&cmdarg_vec, CMDARG_EARLYINIT_FILE,
CMDARG_EARLYINIT_COMMAND, &ret);
+ /* Finish initializing the extension languges. */
+ finish_ext_lang_initialization ();
+
/* Recheck if we're starting up quietly after processing the startup
scripts and commands. */
if (!quiet)
set_language (language_c);
expected_language = current_language; /* Don't warn about the change. */
- /* Python initialization, for example, can require various commands to be
- installed. For example "info pretty-printer" needs the "info"
- prefix to be installed. Keep things simple and just do final
- script initialization here. */
- finish_ext_lang_initialization ();
-
/* Create $_gdb_major and $_gdb_minor convenience variables. */
init_gdb_version_vars ();
}