* cli/cli-dump.c (bfd_openr_with_cleanup): Use gdb_bfd_openr.
[deliverable/binutils-gdb.git] / gdb / gdb_bfd.h
index f5b6103e2fcd3a62863c11bf2b2d3fffebdbbaeb..f131ba777192427ad8cef9a33ad6d412e60aed45 100644 (file)
@@ -58,4 +58,49 @@ void gdb_bfd_unref (struct bfd *abfd);
 
 const gdb_byte *gdb_bfd_map_section (asection *section, bfd_size_type *size);
 
+\f
+
+/* A wrapper for bfd_fopen that initializes the gdb-specific reference
+   count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_fopen (const char *, const char *, const char *, int);
+
+/* A wrapper for bfd_openr that initializes the gdb-specific reference
+   count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_openr (const char *, const char *);
+
+/* A wrapper for bfd_openw that initializes the gdb-specific reference
+   count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_openw (const char *, const char *);
+
+/* A wrapper for bfd_openr_iovec that initializes the gdb-specific
+   reference count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_openr_iovec (const char *filename, const char *target,
+                         void *(*open_func) (struct bfd *nbfd,
+                                             void *open_closure),
+                         void *open_closure,
+                         file_ptr (*pread_func) (struct bfd *nbfd,
+                                                 void *stream,
+                                                 void *buf,
+                                                 file_ptr nbytes,
+                                                 file_ptr offset),
+                         int (*close_func) (struct bfd *nbfd,
+                                            void *stream),
+                         int (*stat_func) (struct bfd *abfd,
+                                           void *stream,
+                                           struct stat *sb));
+
+/* A wrapper for bfd_openr_next_archived_file that initializes the
+   gdb-specific reference count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_openr_next_archived_file (bfd *archive, bfd *previous);
+
+/* A wrapper for bfd_fdopenr that initializes the gdb-specific
+   reference count and calls gdb_bfd_stash_filename.  */
+
+bfd *gdb_bfd_fdopenr (const char *filename, const char *target, int fd);
+
 #endif /* GDB_BFD_H */
This page took 0.026051 seconds and 4 git commands to generate.