2012-11-15 Pierre Muller <muller@sourceware.org>

ARI fixes: move gdb_wait and gdb_stat headers to common subdirectory.
	* gdb_stat.h: Delete. Moved to common directory.
	* common/gdb_stat.h: New file.
	* gdb_wait.h: Delete. Moved to common directory.
	* common/gdb_wait.h: New file.
	* Makefile.in (H_FILES_NO_SRC): Adapt to new header
	location.
	* contrib/ari/gdb_ari.sh (wait.h rule): Adapt to new gdb_wait.h
	location.
	(stat.h rule): Adapt to new gdb_stat.h location.
	* common/linux-osdata.c: Include "gdb_stat.h" header instead of
	<sys/stat.h> header.
	* common/linux-ptrace.c: Include "gdb_wait.h" header instead of
	<sys/wait.h> header.


gdbserver ChangeLog entry:

2012-11-15  Pierre Muller  <muller@sourceware.org>

	* configure.ac (AC_CHECK_HEADERS): Add wait.h header.
	* config.in: Regenerate.
	* configure: Regenerate.
	* linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
	Use "gdb_wait.h" header instead of <sys/wait.h> header.
	* lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
	* remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
	header.
	* server.c: Remove HAVE_WAIT_H conditional.  Use "gdb_wait.h" header
	instead of <sys/wait.h> header.
	* spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
This commit is contained in:
Pierre Muller 2012-11-15 16:12:19 +00:00
parent 3a731e0fc7
commit 8bdce1ffdf
16 changed files with 48 additions and 16 deletions

View file

@ -1,3 +1,20 @@
2012-11-15 Pierre Muller <muller@sourceware.org>
ARI fixes: move gdb_wait and gdb_stat headers to common subdirectory.
* gdb_stat.h: Delete. Moved to common directory.
* common/gdb_stat.h: New file.
* gdb_wait.h: Delete. Moved to common directory.
* common/gdb_wait.h: New file.
* Makefile.in (H_FILES_NO_SRC): Adapt to new header
location.
* contrib/ari/gdb_ari.sh (wait.h rule): Adapt to new gdb_wait.h
location.
(stat.h rule): Adapt to new gdb_stat.h location.
* common/linux-osdata.c: Include "gdb_stat.h" header instead of
<sys/stat.h> header.
* common/linux-ptrace.c: Include "gdb_wait.h" header instead of
<sys/wait.h> header.
2012-11-15 Pierre Muller <muller@sourceware.org> 2012-11-15 Pierre Muller <muller@sourceware.org>
* configure.ac (AC_HEADER_STAT): Remove. * configure.ac (AC_HEADER_STAT): Remove.

View file

@ -781,7 +781,7 @@ gnulib/import/string.in.h gnulib/import/str-two-way.h \
gnulib/import/stdint.in.h remote.h gdb.h sparc-nat.h \ gnulib/import/stdint.in.h remote.h gdb.h sparc-nat.h \
gdbthread.h dwarf2-frame.h dwarf2-frame-tailcall.h nbsd-nat.h dcache.h \ gdbthread.h dwarf2-frame.h dwarf2-frame-tailcall.h nbsd-nat.h dcache.h \
amd64-nat.h s390-tdep.h arm-linux-tdep.h exceptions.h macroscope.h \ amd64-nat.h s390-tdep.h arm-linux-tdep.h exceptions.h macroscope.h \
gdbarch.h bsd-uthread.h gdb_stat.h memory-map.h memrange.h \ gdbarch.h bsd-uthread.h common/gdb_stat.h memory-map.h memrange.h \
mdebugread.h m88k-tdep.h stabsread.h hppa-linux-offsets.h linux-fork.h \ mdebugread.h m88k-tdep.h stabsread.h hppa-linux-offsets.h linux-fork.h \
ser-unix.h inf-ptrace.h terminal.h ui-out.h frame-base.h \ ser-unix.h inf-ptrace.h terminal.h ui-out.h frame-base.h \
f-lang.h dwarf2loc.h value.h sparc-tdep.h defs.h target-descriptions.h \ f-lang.h dwarf2loc.h value.h sparc-tdep.h defs.h target-descriptions.h \
@ -799,7 +799,7 @@ expression.h score-tdep.h gdb_select.h ser-tcp.h buildsym.h valprint.h \
call-cmds.h typeprint.h mi/mi-getopt.h mi/mi-parse.h mi/mi-console.h \ call-cmds.h typeprint.h mi/mi-getopt.h mi/mi-parse.h mi/mi-console.h \
mi/mi-out.h mi/mi-main.h mi/mi-common.h mi/mi-cmds.h linux-nat.h \ mi/mi-out.h mi/mi-main.h mi/mi-common.h mi/mi-cmds.h linux-nat.h \
complaints.h gdb_proc_service.h gdb_regex.h xtensa-tdep.h inf-loop.h \ complaints.h gdb_proc_service.h gdb_regex.h xtensa-tdep.h inf-loop.h \
gdb_wait.h common/gdb_assert.h solib.h ppc-tdep.h cp-support.h glibc-tdep.h \ common/gdb_wait.h common/gdb_assert.h solib.h ppc-tdep.h cp-support.h glibc-tdep.h \
interps.h auxv.h gdbcmd.h tramp-frame.h mipsnbsd-tdep.h \ interps.h auxv.h gdbcmd.h tramp-frame.h mipsnbsd-tdep.h \
amd64-linux-tdep.h linespec.h i387-tdep.h mn10300-tdep.h \ amd64-linux-tdep.h linespec.h i387-tdep.h mn10300-tdep.h \
sparc64-tdep.h monitor.h ppcobsd-tdep.h srec.h solib-pa64.h \ sparc64-tdep.h monitor.h ppcobsd-tdep.h srec.h solib-pa64.h \

View file

@ -26,7 +26,6 @@
#include "linux-osdata.h" #include "linux-osdata.h"
#include <sys/types.h> #include <sys/types.h>
#include <sys/stat.h>
#include <ctype.h> #include <ctype.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
@ -43,6 +42,7 @@
#include "buffer.h" #include "buffer.h"
#include "gdb_assert.h" #include "gdb_assert.h"
#include "gdb_dirent.h" #include "gdb_dirent.h"
#include "gdb_stat.h"
/* Define PID_T to be a fixed size that is at least as large as pid_t, /* Define PID_T to be a fixed size that is at least as large as pid_t,
so that reading pid values embedded in /proc works so that reading pid values embedded in /proc works

View file

@ -27,6 +27,7 @@
#include "linux-procfs.h" #include "linux-procfs.h"
#include "buffer.h" #include "buffer.h"
#include "gdb_assert.h" #include "gdb_assert.h"
#include "gdb_wait.h"
/* Find all possible reasons we could fail to attach PID and append these /* Find all possible reasons we could fail to attach PID and append these
newline terminated reason strings to initialized BUFFER. '\0' termination newline terminated reason strings to initialized BUFFER. '\0' termination
@ -57,7 +58,6 @@ extern void (linux_ptrace_test_ret_to_nx_instr) (void);
#include <sys/reg.h> #include <sys/reg.h>
#include <sys/mman.h> #include <sys/mman.h>
#include <signal.h> #include <signal.h>
#include <sys/wait.h>
#include <stdint.h> #include <stdint.h>
#endif /* defined __i386__ || defined __x86_64__ */ #endif /* defined __i386__ || defined __x86_64__ */

View file

@ -358,7 +358,7 @@ Do not include gnu-regex.h, instead include gdb_regex.h"
BEGIN { doc["stat.h"] = "\ BEGIN { doc["stat.h"] = "\
Do not include stat.h or sys/stat.h, instead include gdb_stat.h" Do not include stat.h or sys/stat.h, instead include gdb_stat.h"
category["stat.h"] = ari_regression category["stat.h"] = ari_regression
fix("stat.h", "gdb/gdb_stat.h", 1) fix("stat.h", "common/gdb_stat.h", 1)
} }
/^#[[:space:]]*include[[:space:]]*.stat\.h./ \ /^#[[:space:]]*include[[:space:]]*.stat\.h./ \
|| /^#[[:space:]]*include[[:space:]]*.sys\/stat\.h./ { || /^#[[:space:]]*include[[:space:]]*.sys\/stat\.h./ {
@ -367,7 +367,7 @@ Do not include stat.h or sys/stat.h, instead include gdb_stat.h"
BEGIN { doc["wait.h"] = "\ BEGIN { doc["wait.h"] = "\
Do not include wait.h or sys/wait.h, instead include gdb_wait.h" Do not include wait.h or sys/wait.h, instead include gdb_wait.h"
fix("wait.h", "gdb/gdb_wait.h", 2); fix("wait.h", "common/gdb_wait.h", 2);
category["wait.h"] = ari_regression category["wait.h"] = ari_regression
} }
/^#[[:space:]]*include[[:space:]]*.wait\.h./ \ /^#[[:space:]]*include[[:space:]]*.wait\.h./ \

View file

@ -1,3 +1,17 @@
2012-11-15 Pierre Muller <muller@sourceware.org>
* configure.ac (AC_CHECK_HEADERS): Add wait.h header.
* config.in: Regenerate.
* configure: Regenerate.
* linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
Use "gdb_wait.h" header instead of <sys/wait.h> header.
* lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
* remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
header.
* server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
instead of <sys/wait.h> header.
* spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
2012-11-13 Markus Metzger <markus.t.metzger@intel.com> 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
* Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER

View file

@ -217,6 +217,9 @@
/* Define to 1 if you have the `vsnprintf' function. */ /* Define to 1 if you have the `vsnprintf' function. */
#undef HAVE_VSNPRINTF #undef HAVE_VSNPRINTF
/* Define to 1 if you have the <wait.h> header file. */
#undef HAVE_WAIT_H
/* Checking if errno must be defined */ /* Checking if errno must be defined */
#undef MUST_DEFINE_ERRNO #undef MUST_DEFINE_ERRNO

View file

@ -4419,7 +4419,7 @@ $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cach
cd "$ac_popdir" cd "$ac_popdir"
for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h proc_service.h sys/procfs.h thread_db.h linux/elf.h stdlib.h unistd.h errno.h fcntl.h signal.h sys/file.h malloc.h sys/ioctl.h netinet/in.h sys/socket.h netdb.h netinet/tcp.h arpa/inet.h sys/wait.h sys/un.h for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h proc_service.h sys/procfs.h thread_db.h linux/elf.h stdlib.h unistd.h errno.h fcntl.h signal.h sys/file.h malloc.h sys/ioctl.h netinet/in.h sys/socket.h netdb.h netinet/tcp.h arpa/inet.h sys/wait.h wait.h sys/un.h
do : do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"

View file

@ -55,7 +55,7 @@ AC_CHECK_HEADERS(sgtty.h termio.h termios.h sys/reg.h string.h dnl
stdlib.h unistd.h dnl stdlib.h unistd.h dnl
errno.h fcntl.h signal.h sys/file.h malloc.h dnl errno.h fcntl.h signal.h sys/file.h malloc.h dnl
sys/ioctl.h netinet/in.h sys/socket.h netdb.h dnl sys/ioctl.h netinet/in.h sys/socket.h netdb.h dnl
netinet/tcp.h arpa/inet.h sys/wait.h sys/un.h) netinet/tcp.h arpa/inet.h sys/wait.h wait.h sys/un.h)
AC_CHECK_FUNCS(pread pwrite pread64 readlink) AC_CHECK_FUNCS(pread pwrite pread64 readlink)
AC_REPLACE_FUNCS(vasprintf vsnprintf) AC_REPLACE_FUNCS(vasprintf vsnprintf)

View file

@ -21,7 +21,7 @@
#include "linux-osdata.h" #include "linux-osdata.h"
#include "agent.h" #include "agent.h"
#include <sys/wait.h> #include "gdb_wait.h"
#include <stdio.h> #include <stdio.h>
#include <sys/param.h> #include <sys/param.h>
#include <sys/ptrace.h> #include <sys/ptrace.h>
@ -40,7 +40,7 @@
#include <pwd.h> #include <pwd.h>
#include <sys/types.h> #include <sys/types.h>
#include <dirent.h> #include <dirent.h>
#include <sys/stat.h> #include "gdb_stat.h"
#include <sys/vfs.h> #include <sys/vfs.h>
#include <sys/uio.h> #include <sys/uio.h>
#ifndef ELFMAG0 #ifndef ELFMAG0

View file

@ -25,7 +25,7 @@
#include <unistd.h> #include <unistd.h>
#include <sys/ioctl.h> #include <sys/ioctl.h>
#include <sys/types.h> #include <sys/types.h>
#include <sys/wait.h> #include "gdb_wait.h"
#include <signal.h> #include <signal.h>
int using_threads = 1; int using_threads = 1;

View file

@ -56,7 +56,7 @@
#if HAVE_ARPA_INET_H #if HAVE_ARPA_INET_H
#include <arpa/inet.h> #include <arpa/inet.h>
#endif #endif
#include <sys/stat.h> #include "gdb_stat.h"
#if HAVE_ERRNO_H #if HAVE_ERRNO_H
#include <errno.h> #include <errno.h>
#endif #endif

View file

@ -27,9 +27,7 @@
#if HAVE_SIGNAL_H #if HAVE_SIGNAL_H
#include <signal.h> #include <signal.h>
#endif #endif
#if HAVE_SYS_WAIT_H #include "gdb_wait.h"
#include <sys/wait.h>
#endif
/* The thread set with an `Hc' packet. `Hc' is deprecated in favor of /* The thread set with an `Hc' packet. `Hc' is deprecated in favor of
`vCont'. Note the multi-process extensions made `vCont' a `vCont'. Note the multi-process extensions made `vCont' a

View file

@ -20,7 +20,7 @@
#include "server.h" #include "server.h"
#include <sys/wait.h> #include "gdb_wait.h"
#include <stdio.h> #include <stdio.h>
#include <sys/ptrace.h> #include <sys/ptrace.h>
#include <fcntl.h> #include <fcntl.h>