Document the GDB 7.7 release in gdb/ChangeLog
[deliverable/binutils-gdb.git] / gdb / auto-load.h
CommitLineData
e2207b9a
JK
1/* GDB routines for supporting auto-loaded scripts.
2
ecd75fc8 3 Copyright (C) 2012-2014 Free Software Foundation, Inc.
e2207b9a
JK
4
5 This file is part of GDB.
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */
19
20#ifndef AUTO_LOAD_H
21#define AUTO_LOAD_H 1
22
23struct program_space;
24
bf88dd68
JK
25struct script_language
26{
5b2bf947
DE
27 /* The name of the language, lowercase. */
28 const char *name;
29
30 /* The suffix added to objfiles to get their auto-load script.
31 E.g., "-gdb.py". */
bf88dd68
JK
32 const char *suffix;
33
5b2bf947
DE
34 /* Returns non-zero if auto-loading scripts in this language is enabled. */
35 int (*auto_load_enabled) (void);
36
37 /* Worker routine to load the script. It has already been opened and
38 deemed safe to load. */
bf88dd68
JK
39 void (*source_script_for_objfile) (struct objfile *objfile, FILE *file,
40 const char *filename);
41};
42
43extern int global_auto_load;
44
45extern int auto_load_local_gdbinit;
46extern char *auto_load_local_gdbinit_pathname;
47extern int auto_load_local_gdbinit_loaded;
e2207b9a
JK
48
49extern struct auto_load_pspace_info *
50 get_auto_load_pspace_data_for_loading (struct program_space *pspace);
51extern int maybe_add_script (struct auto_load_pspace_info *pspace_info,
bccbefd2
JK
52 int loaded, const char *name,
53 const char *full_path,
bf88dd68 54 const struct script_language *language);
bf88dd68 55extern void load_auto_scripts_for_objfile (struct objfile *objfile);
e2207b9a
JK
56extern int
57 script_not_found_warning_print (struct auto_load_pspace_info *pspace_info);
bf88dd68
JK
58extern char auto_load_info_scripts_pattern_nl[];
59extern void auto_load_info_scripts (char *pattern, int from_tty,
60 const struct script_language *language);
61
62extern struct cmd_list_element **auto_load_set_cmdlist_get (void);
63extern struct cmd_list_element **auto_load_show_cmdlist_get (void);
64extern struct cmd_list_element **auto_load_info_cmdlist_get (void);
e2207b9a 65
4dc84fd1
JK
66extern int file_is_auto_load_safe (const char *filename,
67 const char *debug_fmt, ...);
bccbefd2 68
e2207b9a 69#endif /* AUTO_LOAD_H */
This page took 0.229373 seconds and 4 git commands to generate.