#include "filenames.h" /* for DOSish file names */
#include "exec.h"
#include "solist.h"
-#include <readline/readline.h>
+#include "readline/readline.h"
/* external data declarations */
/* If not found, search the solib_search_path (if any). */
if (found_file < 0 && solib_search_path != NULL)
- found_file = openp (solib_search_path,
- 1, in_pathname, O_RDONLY, 0, &temp_pathname);
+ found_file = openp (solib_search_path, OPF_TRY_CWD_FIRST,
+ in_pathname, O_RDONLY, 0, &temp_pathname);
/* If not found, next search the solib_search_path (if any) for the basename
only (ignoring the path). This is to allow reading solibs from a path
that differs from the opened path. */
if (found_file < 0 && solib_search_path != NULL)
- found_file = openp (solib_search_path,
- 1, lbasename (in_pathname), O_RDONLY, 0,
+ found_file = openp (solib_search_path, OPF_TRY_CWD_FIRST,
+ lbasename (in_pathname), O_RDONLY, 0,
&temp_pathname);
/* If not found, try to use target supplied solib search method */
/* If not found, next search the inferior's $PATH environment variable. */
if (found_file < 0 && solib_absolute_prefix == NULL)
found_file = openp (get_in_environ (inferior_environ, "PATH"),
- 1, in_pathname, O_RDONLY, 0, &temp_pathname);
+ OPF_TRY_CWD_FIRST, in_pathname, O_RDONLY, 0,
+ &temp_pathname);
/* If not found, next search the inferior's $LD_LIBRARY_PATH
environment variable. */
if (found_file < 0 && solib_absolute_prefix == NULL)
found_file = openp (get_in_environ (inferior_environ, "LD_LIBRARY_PATH"),
- 1, in_pathname, O_RDONLY, 0, &temp_pathname);
+ OPF_TRY_CWD_FIRST, in_pathname, O_RDONLY, 0,
+ &temp_pathname);
/* Done. If not found, tough luck. Return found_file and
(optionally) found_pathname. */
/* Leave bfd open, core_xfer_memory and "info files" need it. */
so->abfd = abfd;
- abfd->cacheable = 1;
+ bfd_set_cacheable (abfd, 1);
/* copy full path name into so_name, so that later symbol_file_add
can find it */
object's file by the base address to which the object was actually
mapped. */
TARGET_SO_RELOCATE_SECTION_ADDRESSES (so, p);
- if (STREQ (p->the_bfd_section->name, ".text"))
+ if (strcmp (p->the_bfd_section->name, ".text") == 0)
{
so->textsection = p;
}
}
+/* Return address of first so_list entry in master shared object list. */
+struct so_list *
+master_so_list (void)
+{
+ return so_list_head;
+}
+
+
/* A small stub to get us past the arg-passing pinhole of catch_errors. */
static int
add_com ("nosharedlibrary", class_files, no_shared_libraries,
"Unload all shared object library symbols.");
- add_show_from_set
+ deprecated_add_show_from_set
(add_set_cmd ("auto-solib-add", class_support, var_boolean,
(char *) &auto_solib_add,
"Set autoloading of shared library symbols.\n\
"Set prefix for loading absolute shared library symbol files.\n\
For other (relative) files, you can add values using `set solib-search-path'.",
&setlist);
- add_show_from_set (c, &showlist);
+ deprecated_add_show_from_set (c, &showlist);
set_cmd_cfunc (c, reload_shared_libraries);
set_cmd_completer (c, filename_completer);
"Set the search path for loading non-absolute shared library symbol files.\n\
This takes precedence over the environment variables PATH and LD_LIBRARY_PATH.",
&setlist);
- add_show_from_set (c, &showlist);
+ deprecated_add_show_from_set (c, &showlist);
set_cmd_cfunc (c, reload_shared_libraries);
set_cmd_completer (c, filename_completer);
}