[Bug gdb/31865] [gdb] FAIL: gdb.python/tui-window.exp: Window was updated

cvs-commit at gcc dot gnu.org sourceware-bugzilla@sourceware.org
Mon Jun 10 08:42:45 GMT 2024


https://sourceware.org/bugzilla/show_bug.cgi?id=31865

--- Comment #2 from Sourceware Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tom de Vries <vries@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=8ebb6fcd0755717f7c2dd9ff7623e8199b0a88d5

commit 8ebb6fcd0755717f7c2dd9ff7623e8199b0a88d5
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Mon Jun 10 10:43:10 2024 +0200

    gdb: re-add necessary includes in tui/tui-win.c

    Commit 9102a6c15c75 ("gdb/tui: cleanup includes") broke
    gdb.python/tui-window.exp on Linux:

        Running /data/vries/gdb/src/gdb/testsuite/gdb.python/tui-window.exp ...
        WARNING: timeout in accept_gdb_output
        WARNING: timeout in accept_gdb_output
        FAIL: gdb.python/tui-window.exp: Window was updated

    and caused a build failure on AIX:

        CXX    tui/tui-win.o
        tui/tui-win.c: In function 'void tui_sigwinch_handler(int)':
        tui/tui-win.c:532:3: error: 'mark_async_signal_handler' was not
declared in this scope; did you mean 'async_signal_handler'?
          532 |   mark_async_signal_handler (tui_sigwinch_token);
              |   ^~~~~~~~~~~~~~~~~~~~~~~~~
              |   async_signal_handler
        tui/tui-win.c: At global scope:
        tui/tui-win.c:538:1: error: variable or field 'tui_async_resize_screen'
declared void
          538 | tui_async_resize_screen (gdb_client_data arg)
              | ^~~~~~~~~~~~~~~~~~~~~~~
        tui/tui-win.c:538:26: error: 'gdb_client_data' was not declared in this
scope
          538 | tui_async_resize_screen (gdb_client_data arg)
              |                          ^~~~~~~~~~~~~~~
        tui/tui-win.c: In function 'void tui_initialize_win()':
        tui/tui-win.c:579:36: error: 'tui_async_resize_screen' was not declared
in this scope
          579 |     = create_async_signal_handler (tui_async_resize_screen,
NULL,
              |                                    ^~~~~~~~~~~~~~~~~~~~~~~
        tui/tui-win.c:579:7: error: 'create_async_signal_handler' was not
declared in this scope; did you mean 'async_signal_handler'?
          579 |     = create_async_signal_handler (tui_async_resize_screen,
NULL,
              |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
              |       async_signal_handler
        gmake: *** [Makefile:1947: tui/tui-win.o] Error 1

    On Linux, the removal of the signal.h include causes the `#ifdef
    SIGWINCH` sections to become inactive.  The code builds, but then the
    TUI fails to react to terminal size changes.  When we add back the
    inclusion of signal.h, then we see the same build error as on AIX.

    On AIX, I suppose that the SIGWINCH define is still seen by some other
    transitive include.

    When I go back to before 9102a6c15c75, I don't see async-event.h and
    signal.h being marked as unneeded by clangd, so I'm not sure why I
    removed them in the first place... I'll be more careful in the future
    (files with #ifdef/#ifndef can be tricky w.r.t. determining necessary
    includes).

    So, re-add the inclusion of signal.h and async-event.h

    Change-Id: I3ed385c2dc1726ade2118a5186ea7cccffd12635
    Reported-By: Aditya Kamath1 <Aditya.Kamath1@ibm.com>
    Reported-By: Tom de Vries <tdevries@suse.de>
    Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31865

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Gdb-prs mailing list