This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
the current gdbtui code relies on pipe() via TUI_USE_PIPE_FOR_READLINE. this causes build failure for mingw targets if werror is enabled, or link failures if it isnt. since the pipe() code is already conditionalized, it's easy to drop in a configure check for pipe() and only setup this define if pipe() is available. for mingw targets, it wont be, so it'll build & link nicely. in case people are wondering, i'm using the pdcurses implementation for mingw rather than the small stub implementation that is included with gdb for windows targets. the latter does not allow for building of the tui interface as it does not have extended curses features that configure checks for. ok to commit ? mingw32-gcc -g -O2 -D__USE_MINGW_ACCESS -I. -I../../gdb -I../../gdb/common - I../../gdb/config -DLOCALEDIR="\"/usr/local/share/locale\"" -DHAVE_CONFIG_H - I../../gdb/../include/opcode -I../../gdb/../readline/.. -I../bfd - I../../gdb/../bfd -I../../gdb/../include -I../libdecnumber - I../../gdb/../libdecnumber -I./../intl -I../../gdb/gnulib -Ignulib -DMI_OUT=1 -DTUI=1 -Wall -Wdeclaration-after-statement -Wpointer-arith -Wformat- nonliteral -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts - Wno-format -Werror -c -o tui-out.o -MT tui-out.o -MMD -MP -MF .deps/tui- out.Tpo ../../gdb/tui/tui-out.c cc1: warnings being treated as errors ../../gdb/tui/tui-io.c: In function âtui_initialize_ioâ: ../../gdb/tui/tui-io.c:620: error: implicit declaration of function âpipeâ make: *** [tui-io.o] Error 1 i586-mingw32msvc-gcc -g -O2 \ -o gdb.exe gdb.o libgdb.a \ ../sim/bfin/libsim.a ../readline/libreadline.a ../opcodes/libopcodes.a ../bfd/libbfd.a ../libiberty/libiberty.a -lcurses -lm ../libiberty/libiberty.a -lws2_32 libgdb.a(tui-io.o): In function `tui_initialize_io': /usr/local/src/blackfin/svn/toolchain/trunk/binutils-2.17/gdb/tui/tui- io.c:613: undefined reference to `_pipe' collect2: ld returned 1 exit status make: *** [gdb.exe] Error 1 -mike
2009-07-15 Mike Frysinger <vapier@gentoo.org> * configure.ac (AC_CHECK_FUNCS): Check for pipe. * config.in, configure: Regenerate. * tui/tui-io.c (TUI_USE_PIPE_FOR_READLINE): Define if HAVE_PIPE. Index: config.in =================================================================== RCS file: /cvs/src/src/gdb/config.in,v retrieving revision 1.110 diff -u -p -r1.110 config.in --- config.in 23 Apr 2009 21:28:17 -0000 1.110 +++ config.in 15 Jul 2009 19:07:11 -0000 @@ -279,6 +279,9 @@ /* Define if you support the personality syscall. */ #undef HAVE_PERSONALITY +/* Define to 1 if you have the `pipe' function. */ +#undef HAVE_PIPE + /* Define to 1 if you have the `poll' function. */ #undef HAVE_POLL Index: configure =================================================================== RCS file: /cvs/src/src/gdb/configure,v retrieving revision 1.283 diff -u -p -r1.283 configure --- configure 28 May 2009 16:30:37 -0000 1.283 +++ configure 15 Jul 2009 19:07:12 -0000 @@ -15868,7 +15868,7 @@ fi for ac_func in canonicalize_file_name realpath getrusage getuid \ - getgid poll pread64 sbrk setpgid setpgrp setsid \ + getgid pipe poll pread64 sbrk setpgid setpgrp setsid \ sigaction sigprocmask sigsetmask socketpair syscall \ ttrace wborder setlocale iconvlist libiconvlist btowc do Index: configure.ac =================================================================== RCS file: /cvs/src/src/gdb/configure.ac,v retrieving revision 1.102 diff -u -p -r1.102 configure.ac --- configure.ac 28 May 2009 16:30:37 -0000 1.102 +++ configure.ac 15 Jul 2009 19:07:13 -0000 @@ -785,7 +785,7 @@ AC_FUNC_ALLOCA AC_FUNC_MMAP AC_FUNC_VFORK AC_CHECK_FUNCS([canonicalize_file_name realpath getrusage getuid \ - getgid poll pread64 sbrk setpgid setpgrp setsid \ + getgid pipe poll pread64 sbrk setpgid setpgrp setsid \ sigaction sigprocmask sigsetmask socketpair syscall \ ttrace wborder setlocale iconvlist libiconvlist btowc]) AM_LANGINFO_CODESET Index: tui/tui-io.c =================================================================== RCS file: /cvs/src/src/gdb/tui/tui-io.c,v retrieving revision 1.20 diff -u -p -r1.20 tui-io.c --- tui/tui-io.c 3 Jan 2009 05:58:08 -0000 1.20 +++ tui/tui-io.c 15 Jul 2009 19:07:13 -0000 @@ -113,7 +113,9 @@ key_is_command_char (int ch) #undef TUI_USE_PIPE_FOR_READLINE. */ /* For gdb 5.3, prefer to continue the pipe hack as a backup wheel. */ +#ifdef HAVE_PIPE #define TUI_USE_PIPE_FOR_READLINE +#endif /* #undef TUI_USE_PIPE_FOR_READLINE */ /* TUI output files. */
Attachment:
signature.asc
Description: This is a digitally signed message part.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |