public inbox for insight@sourceware.org
 help / color / mirror / Atom feed
* RE: don't check uselessly for headers
       [not found] <87390c2dy8.fsf@fleche.redhat.com>
@ 2012-11-15 10:11 ` Pierre Muller
  2012-11-16 23:16   ` Keith Seitz
  0 siblings, 1 reply; 2+ messages in thread
From: Pierre Muller @ 2012-11-15 10:11 UTC (permalink / raw)
  To: 'Tom Tromey', 'Keith Seitz'; +Cc: insight

 Hi Tom,

  gdbtk directory is still also using HAVE_CTYPE_H...
  This needs a fix to restore compilation for insight.

Keith,
  Could you test and check this patch in if it works,
I have no system on which I can compile insight currently :(

Pierre Muller




Index: ChangeLog
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/ChangeLog,v
retrieving revision 1.485
diff -u -p -r1.485 ChangeLog
--- ChangeLog   10 Nov 2012 18:09:30 -0000      1.485
+++ ChangeLog   15 Nov 2012 10:07:00 -0000
@@ -1,3 +1,9 @@
+2012-11-15  Pierre Muller  <muller@sourceware.org>
+
+       Adapt to change in gdb/configure.ac
+       Don't check for ctype.h, time.h.
+       * generic/gdbtk-cmds.c: Don't use HAVE_CTYPE_H.
+
 2012-11-10  Keith Seitz  <keiths@redhat.com>

        * generic/gdbtk-bp.c (breakpoint_notify): Fix logic error
cvs diff: Diffing generic
Index: generic/gdbtk-cmds.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/generic/gdbtk-cmds.c,v
retrieving revision 1.129
diff -u -p -r1.129 gdbtk-cmds.c
--- generic/gdbtk-cmds.c        10 Oct 2012 17:28:03 -0000      1.129
+++ generic/gdbtk-cmds.c        15 Nov 2012 10:07:01 -0000
@@ -88,9 +88,7 @@
 # endif
 #endif

-#ifdef HAVE_CTYPE_H
 #include <ctype.h>             /* for isprint() */
-#endif

 #ifdef _WIN32
 #include <windows.h>    /* For gdb_list_processes() */


  
> -----Message d'origine-----
> De : gdb-patches-owner@sourceware.org [mailto:gdb-patches-
> owner@sourceware.org] De la part de Tom Tromey
> Envoyé : mercredi 14 novembre 2012 20:16
> À : gdb-patches@sourceware.org
> Objet : FYI: don't check uselessly for headers
> 
> I'm checking this in.
> 
> While looking at importing more of gnulib, I noticed that gdb's
> configure script is checking for ctype.h and time.h -- but there are no
> uses of HAVE_TIME_H and only a single use of HAVE_CTYPE_H.  So, per the
> existing comment, these checks are useless.
> 
> This patch removes the checks and updates the one place using
> HAVE_CTYPE_H.
> 
> Tested by rebuilding.
> 
> Tom
> 
> 2012-11-14  Tom Tromey  <tromey@redhat.com>
> 
> 	* configure, config.in: Rebuild.
> 	* configure.ac: Don't check for ctype.h, time.h.
> 	* expprint.c: Don't use HAVE_CTYPE_H.
> 
> Index: configure.ac
> ===================================================================
> RCS file: /cvs/src/src/gdb/configure.ac,v
> retrieving revision 1.186
> diff -u -r1.186 configure.ac
> --- configure.ac	2 Nov 2012 18:53:54 -0000	1.186
> +++ configure.ac	14 Nov 2012 19:12:05 -0000
> @@ -1075,8 +1075,6 @@
>  AC_HEADER_STAT
>  AC_HEADER_STDC
>  # elf_hp.h is for HP/UX 64-bit shared library support.
> -# FIXME: kettenis/20030102: In most cases we include these (ctype.h,
> time.h)
> -# unconditionally, so what's the point in checking these?
>  AC_CHECK_HEADERS([nlist.h machine/reg.h poll.h sys/poll.h proc_service.h
\
>                    thread_db.h signal.h stddef.h \
>  		  stdlib.h string.h memory.h strings.h sys/fault.h \
> @@ -1084,7 +1082,7 @@
>  		  sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
>  		  sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
>  		  sys/types.h sys/wait.h wait.h termios.h termio.h \
> -		  sgtty.h unistd.h elf_hp.h ctype.h time.h locale.h \
> +		  sgtty.h unistd.h elf_hp.h locale.h \
>  		  dlfcn.h sys/socket.h sys/un.h])
>  AC_CHECK_HEADERS(link.h, [], [],
>  [#if HAVE_SYS_TYPES_H
> Index: expprint.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/expprint.c,v
> retrieving revision 1.63
> diff -u -r1.63 expprint.c
> --- expprint.c	13 Nov 2012 09:46:10 -0000	1.63
> +++ expprint.c	14 Nov 2012 19:12:06 -0000
> @@ -33,9 +33,7 @@
>  #include "gdb_assert.h"
>  #include "valprint.h"
> 
> -#ifdef HAVE_CTYPE_H
>  #include <ctype.h>
> -#endif
> 
>  void
>  print_expression (struct expression *exp, struct ui_file *stream)

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: don't check uselessly for headers
  2012-11-15 10:11 ` don't check uselessly for headers Pierre Muller
@ 2012-11-16 23:16   ` Keith Seitz
  0 siblings, 0 replies; 2+ messages in thread
From: Keith Seitz @ 2012-11-16 23:16 UTC (permalink / raw)
  To: Pierre Muller; +Cc: insight

On 11/15/2012 02:10 AM, Pierre Muller wrote:

>    Could you test and check this patch in if it works,
> I have no system on which I can compile insight currently :(

I have checked this out and committed it. Thank you for thinking of us!

Keith

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-11-16 23:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <87390c2dy8.fsf@fleche.redhat.com>
2012-11-15 10:11 ` don't check uselessly for headers Pierre Muller
2012-11-16 23:16   ` Keith Seitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).