]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gdb: remove find_and_open_solib so_list method
authorSimon Marchi <simon.marchi@polymtl.ca>
Thu, 25 Jul 2024 17:41:37 +0000 (13:41 -0400)
committerSimon Marchi <simon.marchi@efficios.com>
Mon, 12 Aug 2024 14:21:15 +0000 (10:21 -0400)
Now that the nto port is removed, this is unused.

Change-Id: I86565310cdbcde17a837eb10585cdd153f4f03d8
Approved-by: Kevin Buettner <kevinb@redhat.com>
gdb/solib-svr4.c
gdb/solib.c
gdb/solist.h

index 9f377f427c878883488a57a9adfdabc4eb02e7be..8c3ff39d2ac0c600121930b4f8590f3f12dfc246 100644 (file)
@@ -3364,7 +3364,6 @@ const struct solib_ops svr4_so_ops =
   open_symbol_file_object,
   svr4_in_dynsym_resolve_code,
   solib_bfd_open,
-  nullptr,
   svr4_same,
   svr4_keep_data_in_core,
   svr4_update_solib_event_breakpoints,
index 931fa571be25c29a3047507ec221330de4d1f467..49f607514dc7500549717a2fc08bab804ba11fc7 100644 (file)
@@ -114,7 +114,6 @@ show_solib_search_path (struct ui_file *file, int from_tty,
 static gdb::unique_xmalloc_ptr<char>
 solib_find_1 (const char *in_pathname, int *fd, bool is_solib)
 {
-  const solib_ops *ops = gdbarch_so_ops (current_inferior ()->arch ());
   int found_file = -1;
   gdb::unique_xmalloc_ptr<char> temp_pathname;
   const char *fskind = effective_target_file_system_kind ();
@@ -297,12 +296,6 @@ solib_find_1 (const char *in_pathname, int *fd, bool is_solib)
                        target_lbasename (fskind, in_pathname),
                        O_RDONLY | O_BINARY, &temp_pathname);
 
-  /* If not found, and we're looking for a solib, try to use target
-     supplied solib search method.  */
-  if (is_solib && found_file < 0 && ops->find_and_open_solib)
-    found_file = ops->find_and_open_solib (in_pathname, O_RDONLY | O_BINARY,
-                                          &temp_pathname);
-
   /* If not found, next search the inferior's $PATH environment variable.  */
   if (found_file < 0 && sysroot == NULL)
     found_file = openp (current_inferior ()->environment.get ("PATH"),
index f0d22080de1781c93bc9f7c7e77b138e59fac65c..6b2a97adf7a7c1ca72762b26d5d8a77c167e012b 100644 (file)
@@ -132,14 +132,6 @@ struct solib_ops
   /* Find and open shared library binary file.  */
   gdb_bfd_ref_ptr (*bfd_open) (const char *pathname);
 
-  /* Optional extra hook for finding and opening a solib.
-     If TEMP_PATHNAME is non-NULL: If the file is successfully opened a
-     pointer to a malloc'd and realpath'd copy of SONAME is stored there,
-     otherwise NULL is stored there.  */
-  int (*find_and_open_solib) (const char *soname,
-                             unsigned o_flags,
-                             gdb::unique_xmalloc_ptr<char> *temp_pathname);
-
   /* Given two so_list objects, one from the GDB thread list
      and another from the list returned by current_sos, return 1
      if they represent the same library.