From 6dddd6a5747532ef6e9703432c51680011df4e8d Mon Sep 17 00:00:00 2001 From: Doug Evans Date: Fri, 12 Dec 2014 09:48:13 -0800 Subject: New python function gdb.lookup_objfile. gdb/ChangeLog: * NEWS: Mention gdb.lookup_objfile. * python/python.c (GdbMethods): Add lookup_objfile. * python/python-internal.h (gdbpy_lookup_objfile): Declare. * python/py-objfile.c: #include "symtab.h". (objfpy_build_id_ok, objfpy_build_id_matches): New functions. (objfpy_lookup_objfile_by_name): New function. (objfpy_lookup_objfile_by_build_id): New function. (gdbpy_lookup_objfile): New function. gdb/doc/ChangeLog: * python.texi (Objfiles In Python): Document gdb.lookup_objfile. gdb/testsuite/ChangeLog: * lib/gdb-python.exp (get_python_valueof): New function. * gdb.python/py-objfile.exp: Add tests for gdb.lookup_objfile. --- gdb/python/python-internal.h | 1 + 1 file changed, 1 insertion(+) (limited to 'gdb/python/python-internal.h') diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h index 716c0de..544fe93 100644 --- a/gdb/python/python-internal.h +++ b/gdb/python/python-internal.h @@ -393,6 +393,7 @@ PyObject *objfile_to_objfile_object (struct objfile *) PyObject *objfpy_get_printers (PyObject *, void *); PyObject *objfpy_get_frame_filters (PyObject *, void *); PyObject *objfpy_get_xmethods (PyObject *, void *); +PyObject *gdbpy_lookup_objfile (PyObject *self, PyObject *args, PyObject *kw); PyObject *gdbarch_to_arch_object (struct gdbarch *gdbarch); -- cgit v1.1