[oe-commits] Khem Raj : gdb_7.1: Add patch to shut a warning when we boot into shell.

git version control git at git.openembedded.org
Thu Jun 10 04:04:53 CEST 2010


Module: openembedded.git
Branch: org.openembedded.dev
Commit: 8b17bc55a9191ff36a0788aac87da522286714d8
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=8b17bc55a9191ff36a0788aac87da522286714d8

Author: Khem Raj <raj.khem at gmail.com>
Date:   Wed Jun  9 19:04:02 2010 -0700

gdb_7.1: Add patch to shut a warning when we boot into shell.

* [tcsetpgrp failed in terminal_inferior: Inappropriate ioctl for
* device]
  this warning is pretty annoying when debugging on a shell which
  does not have a proper console device allocated and no job control.

Signed-off-by: Khem Raj <raj.khem at gmail.com>

---

 recipes/gdb/gdb-7.1/gdb-tcsetpgrp.patch |   43 +++++++++++++++++++++++++++++++
 recipes/gdb/gdb_7.1.bb                  |    7 +++-
 2 files changed, 48 insertions(+), 2 deletions(-)

diff --git a/recipes/gdb/gdb-7.1/gdb-tcsetpgrp.patch b/recipes/gdb/gdb-7.1/gdb-tcsetpgrp.patch
new file mode 100644
index 0000000..d642721
--- /dev/null
+++ b/recipes/gdb/gdb-7.1/gdb-tcsetpgrp.patch
@@ -0,0 +1,43 @@
+Stuart Hughes, stuarth at freescale.com 8th April 05
+
+Extracted from:
+
+From: Davin Milun (milun at cs.buffalo.edu)
+Subject: Re: xxgdb for Solaris
+View: Complete Thread (4 articles)
+Original Format
+Newsgroups: comp.unix.solaris
+Date: 1995/05/05
+
+Geraldo Veiga <ggv at research.att.com> wrote:
+>Now, how do I avoid those
+>
+>[tcsetpgrp failed in terminal_inferior: Inappropriate ioctl for device]
+>
+>messages at every step the program takes under mxgdb (and xxgdb)?.  I am
+>running GDB4.13 under Solaris 2.4.  
+
+You need to patch inflow.c.
+
+
+ diff --exclude CVS -uNr gdb-6.0/gdb/inflow.c gdb-6.0.modified/gdb/inflow.c
+Index: gdb-7.1/gdb/inflow.c
+===================================================================
+--- gdb-7.1.orig/gdb/inflow.c	2010-01-21 06:26:12.000000000 -0800
++++ gdb-7.1/gdb/inflow.c	2010-06-09 13:59:33.761358724 -0700
+@@ -308,13 +308,13 @@ terminal_inferior (void)
+ 	{
+ #ifdef HAVE_TERMIOS
+ 	  result = tcsetpgrp (0, tinfo->process_group);
+-	  if (!inf->attach_flag)
++	  if (!inf->attach_flag && errno != ENOTTY)
+ 	    OOPSY ("tcsetpgrp");
+ #endif
+ 
+ #ifdef HAVE_SGTTY
+ 	  result = ioctl (0, TIOCSPGRP, &tinfo->process_group);
+-	  if (!inf->attach_flag)
++	  if (!inf->attach_flag && errno != ENOTTY)
+ 	    OOPSY ("TIOCSPGRP");
+ #endif
+ 	}
diff --git a/recipes/gdb/gdb_7.1.bb b/recipes/gdb/gdb_7.1.bb
index 5489c80..a73eb72 100644
--- a/recipes/gdb/gdb_7.1.bb
+++ b/recipes/gdb/gdb_7.1.bb
@@ -1,8 +1,11 @@
 require gdb.inc
 LICENSE = "GPLv3"
 
-SRC_URI += "\
-            file://gdb-6.8-fix-compile-karmic.patch"
+PR = "r1"
+
+SRC_URI += "file://gdb-6.8-fix-compile-karmic.patch \
+	    file://gdb-tcsetpgrp.patch \
+	   "
 
 # Work-around problems while creating libbfd.a
 EXTRA_OECONF += "--enable-static"




More information about the Openembedded-commits mailing list