From 6bf0ce2beda67e4101c734c8911c2aa9a7924833 Mon Sep 17 00:00:00 2001 From: Paul Pluzhnikov Date: Thu, 28 May 2009 16:30:39 +0000 Subject: [PATCH] 2009-05-28 Pierre Muller Paul Pluzhnikov * configure.ac (!have_libpython): Add python-prettyprint source and object files. * configure: Regenerate. * python/python-prettyprint.c: Move "#ifdef HAVE_PYTHON" before python headers. --- gdb/ChangeLog | 9 +++++++++ gdb/configure | 4 ++-- gdb/configure.ac | 4 ++-- gdb/python/python-prettyprint.c | 9 +++++---- 4 files changed, 18 insertions(+), 8 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index fec8eb2b3fb..a5aba7e993e 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,12 @@ +2009-05-28 Pierre Muller + Paul Pluzhnikov + + * configure.ac (!have_libpython): Add python-prettyprint source + and object files. + * configure: Regenerate. + * python/python-prettyprint.c: Move "#ifdef HAVE_PYTHON" before + python headers. + 2009-05-27 Vladimir Prus Tom Tromey Thiago Jung Bauermann diff --git a/gdb/configure b/gdb/configure index 449e8762481..13b30f850d4 100755 --- a/gdb/configure +++ b/gdb/configure @@ -11907,8 +11907,8 @@ echo "${ECHO_T}${PYTHON_CFLAGS}" >&6 else # Even if Python support is not compiled in, we need to have these files # included in order to recognize the GDB command "python". - CONFIG_OBS="$CONFIG_OBS python.o python-value.o" - CONFIG_SRCS="$CONFIG_SRCS python/python.c python/python-value.c" + CONFIG_OBS="$CONFIG_OBS python.o python-value.o python-prettyprint.o" + CONFIG_SRCS="$CONFIG_SRCS python/python.c python/python-value.c python/python-prettyprint.c" fi diff --git a/gdb/configure.ac b/gdb/configure.ac index af396cc137e..1d91647e34a 100644 --- a/gdb/configure.ac +++ b/gdb/configure.ac @@ -685,8 +685,8 @@ if test "${have_libpython}" = yes; then else # Even if Python support is not compiled in, we need to have these files # included in order to recognize the GDB command "python". - CONFIG_OBS="$CONFIG_OBS python.o python-value.o" - CONFIG_SRCS="$CONFIG_SRCS python/python.c python/python-value.c" + CONFIG_OBS="$CONFIG_OBS python.o python-value.o python-prettyprint.o" + CONFIG_SRCS="$CONFIG_SRCS python/python.c python/python-value.c python/python-prettyprint.c" fi AC_SUBST(PYTHON_CFLAGS) diff --git a/gdb/python/python-prettyprint.c b/gdb/python/python-prettyprint.c index 6e17f9ad701..117a5e4ca1f 100644 --- a/gdb/python/python-prettyprint.c +++ b/gdb/python/python-prettyprint.c @@ -23,10 +23,12 @@ #include "symtab.h" #include "language.h" #include "valprint.h" + #include "python.h" -#include "python-internal.h" #ifdef HAVE_PYTHON +#include "python-internal.h" + /* Helper function for find_pretty_printer which iterates over a list, calls each function and inspects output. This will return a @@ -587,9 +589,8 @@ gdbpy_default_visualizer (PyObject *self, PyObject *args) int apply_val_pretty_printer (struct type *type, const gdb_byte *valaddr, int embedded_offset, CORE_ADDR address, - struct ui_file *stream, int format, - int deref_ref, int recurse, - enum val_prettyprint pretty, + struct ui_file *stream, int recurse, + const struct value_print_options *options, const struct language_defn *language) { return 0; -- 2.30.2