* python/py-autoload.c (print_script): Print "Missing" instead of
authorDoug Evans <dje@google.com>
Sun, 15 May 2011 18:46:25 +0000 (18:46 +0000)
committerDoug Evans <dje@google.com>
Sun, 15 May 2011 18:46:25 +0000 (18:46 +0000)
"No" for missing scripts.
(info_auto_load_scripts): Tweak "Loaded" column to fit "Missing".

doc/
* gdb.texinfo (Auto-loading): Document printing of missing scripts.

gdb/ChangeLog
gdb/doc/ChangeLog
gdb/doc/gdb.texinfo
gdb/python/py-auto-load.c

index 5ee25e90b32f89329064e54fc3188240fd0ed43a..df5048124c6b93a3d0e81e5965df28ef6a7f4617 100644 (file)
@@ -1,3 +1,9 @@
+2011-05-15  Doug Evans  <dje@google.com>
+
+       * python/py-autoload.c (print_script): Print "Missing" instead of
+       "No" for missing scripts.
+       (info_auto_load_scripts): Tweak "Loaded" column to fit "Missing".
+
 2011-05-13  Doug Evans  <dje@google.com>
 
        * ui-file.c (stdio_file_write_async_safe): Add comment.
index f1455740b6e10fdf8b7dce5da9a7386b95637ab6..bbb855d4c8cc51f6865747e1d5dafcdb011a655d 100644 (file)
@@ -1,3 +1,7 @@
+2011-05-15  Doug Evans  <dje@google.com>
+
+       * gdb.texinfo (Auto-loading): Document printing of missing scripts.
+
 2011-05-13  Doug Evans  <dje@google.com>
 
        * gdb.texinfo (Threads): Document $sdir,$pdir.
index 08ee158ea5ad4c9f32c3feeff1fd1464eff02ae2..7fe6aac0d3487be815967f0f4ecf2801a860ffce 100644 (file)
@@ -23601,14 +23601,25 @@ Show whether auto-loading of Python scripts is enabled or disabled.
 @kindex info auto-load-scripts
 @cindex print list of auto-loaded scripts
 @item info auto-load-scripts [@var{regexp}]
-Print the list of all scripts that gdb auto-loaded, or tried to auto-load.
+Print the list of all scripts that @value{GDBN} auto-loaded.
+
+Also printed is the list of scripts that were mentioned in
+the @code{.debug_gdb_scripts} section and were not found
+(@pxref{.debug_gdb_scripts section}).
+This is useful because their names are not printed when @value{GDBN}
+tries to load them and fails.  There may be many of them, and printing
+an error message for each one is problematic.
+
 If @var{regexp} is supplied only scripts with matching names are printed.
 
+Example:
+
 @smallexample
 (gdb) info auto-load-scripts
-Loaded Script                                                                 
-  Yes  py-section-script.py
-       full name: /tmp/py-section-script.py
+Loaded  Script
+Yes     py-section-script.py
+        full name: /tmp/py-section-script.py
+Missing my-foo-pretty-printers.py
 @end smallexample
 @end table
 
index 4f31c2acb6a7ef9df2d7bc7469175ec6d4426e00..4024fd3f489940cc5fe42493a30322b56ca79c43 100644 (file)
@@ -497,7 +497,7 @@ print_script (struct loaded_script *script)
 
   chain = make_cleanup_ui_out_tuple_begin_end (uiout, NULL);
 
-  ui_out_field_string (uiout, "loaded", script->full_path ? "Yes" : "No");
+  ui_out_field_string (uiout, "loaded", script->full_path ? "Yes" : "Missing");
   ui_out_field_string (uiout, "script", script->name);
   ui_out_text (uiout, "\n");
 
@@ -569,7 +569,7 @@ info_auto_load_scripts (char *pattern, int from_tty)
   make_cleanup_ui_out_table_begin_end (uiout, 2, nr_scripts,
                                       "AutoLoadedScriptsTable");
 
-  ui_out_table_header (uiout, 6, ui_center, "loaded", "Loaded");
+  ui_out_table_header (uiout, 7, ui_left, "loaded", "Loaded");
   ui_out_table_header (uiout, 70, ui_left, "script", "Script");
   ui_out_table_body (uiout);