public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  master:  * Undo last wrong patch
@ 2011-03-19 21:27 muller
  0 siblings, 0 replies; only message in thread
From: muller @ 2011-03-19 21:27 UTC (permalink / raw)
  To: archer-commits

The branch, master has been updated
       via  c40415cfe4d602ded27d296c771006609596d5f4 (commit)
      from  e65e6659973dc8554f75f731491986720d7f3929 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit c40415cfe4d602ded27d296c771006609596d5f4
Author: Pierre Muller <muller@ics.u-strasbg.fr>
Date:   Sat Mar 19 22:27:17 2011 +0100

     * Undo last wrong patch

-----------------------------------------------------------------------

Summary of changes:
 gdb/Makefile.in                |    6 -
 gdb/common/windows-hdep.c      |  236 ----------
 gdb/common/windows-hdep.h      |  134 ------
 gdb/configure.host             |    8 +-
 gdb/gdbserver/Makefile.in      |    8 -
 gdb/gdbserver/configure.srv    |   10 +-
 gdb/gdbserver/win32-low.c      |   17 +-
 gdb/mingw-hdep.c               |    6 -
 gdb/nto-tdep.c                 |    6 +-
 gdb/p-lang.h                   |   26 +-
 gdb/regformats/regdat.sh       |   10 -
 gdb/remote-fileio.c            |   37 +-
 gdb/remote-mips.c              |    3 -
 gdb/testsuite/gdb.base/dbx.exp |    2 +-
 gdb/testsuite/lib/gdb.exp      |  153 ------
 gdb/testsuite/lib/pascal.exp   |   23 -
 gdb/windows-nat.c              | 1017 ++++++++--------------------------------
 gdb/windows-tdep.c             |   38 +--
 18 files changed, 265 insertions(+), 1475 deletions(-)
 delete mode 100644 gdb/common/windows-hdep.c
 delete mode 100644 gdb/common/windows-hdep.h

First 500 lines of diff:
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 2783af9..489b1e9 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -1120,7 +1120,6 @@ init.c: $(INIT_FILES)
 	    -e '/[a-z0-9A-Z_]*-exp.tab.[co]$$/d' \
 	    -e 's/\.[co]$$/.c/' \
 	    -e 's,signals\.c,common/signals\.c,' \
-	    -e 's,windows-hdep\.c,common/windows-hdep\.c,' \
 	    -e 's|^\([^  /][^     ]*\)|$(srcdir)/\1|g' | \
 	while read f; do \
 	    sed -n -e 's/^_initialize_\([a-z_0-9A-Z]*\).*/\1/p' $$f 2>/dev/null; \
@@ -1912,10 +1911,6 @@ signals.o: $(srcdir)/common/signals.c
 	$(COMPILE) $(srcdir)/common/signals.c
 	$(POSTCOMPILE)
 
-windows-hdep.o: $(srcdir)/common/windows-hdep.c
-	$(COMPILE) $(srcdir)/common/windows-hdep.c
-	$(POSTCOMPILE)
-
 #
 # gdb/tui/ dependencies
 #
@@ -1994,7 +1989,6 @@ tui-winsource.o: $(srcdir)/tui/tui-winsource.c
 	$(COMPILE) $(srcdir)/tui/tui-winsource.c
 	$(POSTCOMPILE)
 
-
 #
 # gdb/python/ dependencies
 #
diff --git a/gdb/common/windows-hdep.c b/gdb/common/windows-hdep.c
deleted file mode 100644
index 315a983..0000000
--- a/gdb/common/windows-hdep.c
+++ /dev/null
@@ -1,236 +0,0 @@
-/* Copyright 2011 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
-
-/* The primary purpose of this file is to implement conversion between
-   POSIX style and Windows NATIVE style path and path lists.
-   For this purpose, generic replacement of the two cygwin function
-   cygwin_conv_path and cygwin_conv_path_list are created.  */
-
-#include <winsock2.h>
-#include <windows.h>
-#include <sys/types.h>
-#include <string.h>
-
-#ifndef GDBSERVER
-# include "defs.h"
-# include "gdb_assert.h"
-#else
-# include "server.h"
-#endif
-#include "windows-hdep.h"
-
-int
-gdb_win_conv_path (conv_type oper, const void *from, void * to, int size)
-{
-#ifdef USE_MINGW_CONV
-  if (size == 0)
-    {
-#ifdef USE_WIDE_WINAPI
-      if (oper == WINDOWS_POSIX_TO_NATIVE_W)
-	return MultiByteToWideChar (CP_ACP, 0, from, -1, to, 0);
-      if (oper == WINDOWS_NATIVE_W_TO_POSIX)
-	return WideCharToMultiByte (CP_ACP, 0, from, -1, to, 0, 0, 0);
-      else
-#endif /* USE_WIDE_WINAPI */
-        return (strlen((const char *) from) + 1);
-    }
-  else
-    {
-      int len = strlen((const char *) from) + 1;
-#ifdef USE_WIDE_WINAPI
-      if (oper == WINDOWS_POSIX_TO_NATIVE_W)
-	return MultiByteToWideChar (CP_ACP, 0, from, len, to, size);
-      if (oper == WINDOWS_NATIVE_W_TO_POSIX)
-	return WideCharToMultiByte (CP_ACP, 0, from, len, to, size, 0, 0);
-      else
-#endif /* USE_WIDE_WINAPI */
-        {
-	  if (size < len)
-	    len = size;
-	  strncpy ((char *) to, (const char *) from, len);
-	  if (oper == WINDOWS_NATIVE_TO_MSYS)
-	    {
-	      char * p;
-	      p = strchr (to, '\\');
-	      while (p)
-		{
-		  *p = '/';
-		  p = strchr (to, '\\');
-		}
-	      if (((char *) to)[1] == ':' && ((char *) to)[2] == '/')
-		{
-		  char drive = ((char *) to)[0];
-		  ((char *) to)[0] = '/';
-		  ((char *) to)[1] = drive;
-		}
-
-	    }
-          /* For null termination.  */
-	  if (len == size)
-	    ((char *) to)[size] = '\0';
-	}
-      return len;
-    }
-#endif /* USE_MING_CONV */
-#ifdef USE_NEW_CYGWIN_CONV
-  int op;
-
-  switch (oper)
-    {
-    case WINDOWS_NATIVE_W_TO_POSIX:
-      op = CCP_WIN_W_TO_POSIX;
-      break;
-
-    case WINDOWS_NATIVE_A_TO_POSIX:
-    case WINDOWS_NATIVE_TO_MSYS:
-      op = CCP_WIN_A_TO_POSIX;
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_W:
-      op = CCP_POSIX_TO_WIN_W;
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_A:
-      op = CCP_POSIX_TO_WIN_A;
-      break;
-    default:
-      {
-	int len = strlen((const char *) from) + 1;
-
-	strncpy ((char *) to, (const char *) from, size);
-	return len;
-      }
-    }
-
-  return (cygwin_conv_path (op, from, to, size));
-#endif /* USE_NEW_CYGWIN_CONV */
-#ifdef USE_OLD_CYGWIN_CONV
-  switch (oper)
-  /* Those two macros:
-     WINDOWS_NATIVE_W_TO_POSIX and WINDOWS_POSIX_TO_NATIVE_W
-     are not defined for old Cygwin, and thus not handled here .  */
-    {
-    case WINDOWS_NATIVE_A_TO_POSIX:
-    case WINDOWS_NATIVE_TO_MSYS:
-      if (size == 0)
-	return __PMAX;
-      gdb_assert (size >= __PMAX);
-      return cygwin_conv_to_full_posix_path (from, to);
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_A:
-      if (size == 0)
-	return __PMAX;
-      gdb_assert (size >= __PMAX);
-      return cygwin_conv_to_win32_path (from, to);
-      break;
-    };
-  return -1;
-#endif /* USE_OLD_CYGWIN_CONV */
-}
-
-/* Analogeous function for PATH style lists.  */
-
-int
-gdb_win_conv_path_list (conv_type oper, const void *from, void * to, int size)
-{
-#ifdef USE_MINGW_CONV
-#ifdef USE_WIDE_WINAPI
-  switch (oper)
-    {
-    case WINDOWS_NATIVE_W_TO_POSIX:
-    case WINDOWS_POSIX_TO_NATIVE_W:
-      return -1;
-    default:
-      ;
-    }
-#endif /* USE_WIDE_WINAPI */
-  if (size == 0)
-    return (strlen((const char *) from) + 1);
-  else
-    {
-      int len = strlen((const char *) from) + 1;
-      if (len > size)
-	len = size;
-      strncpy ((char *) to, (const char *) from, len);
-      /* For null termination.  */
-      if (len == size)
-	((char *) to)[size] = '\0';
-      return len;
-    }
-#endif /* USE_MING_CONV */
-#ifdef USE_NEW_CYGWIN_CONV
-  int op;
-
-  switch (oper)
-    {
-    case WINDOWS_NATIVE_W_TO_POSIX:
-      op = CCP_WIN_W_TO_POSIX;
-      break;
-
-    case WINDOWS_NATIVE_A_TO_POSIX:
-    case WINDOWS_NATIVE_TO_MSYS:
-      op = CCP_WIN_A_TO_POSIX;
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_W:
-      op = CCP_POSIX_TO_WIN_W;
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_A:
-      op = CCP_POSIX_TO_WIN_A;
-      break;
-    };
-
-  return (cygwin_conv_path_list (op, from, to, size));
-#endif /* USE_NEW_CYGWIN_CONV */
-#ifdef USE_OLD_CYGWIN_CONV
-  switch (oper)
-  /* Those two macros:
-     WINDOWS_NATIVE_W_TO_POSIX and WINDOWS_POSIX_TO_NATIVE_W
-     are not defined for old Cygwin, and thus not handled here .  */
-    {
-    case WINDOWS_NATIVE_A_TO_POSIX:
-    case WINDOWS_NATIVE_TO_MSYS:
-      if (size == 0)
-	return cygwin_win32_to_posix_path_list_buf_size (from);
-      gdb_assert (size >= cygwin_win32_to_posix_path_list_buf_size (from));
-      return cygwin_win32_to_posix_path_list (from, to);
-      break;
-
-    case WINDOWS_POSIX_TO_NATIVE_A:
-      if (size == 0)
-         return cygwin_posix_to_win32_path_list_buf_size (from);
-      gdb_assert (size >= cygwin_posix_to_win32_path_list_buf_size (from));
-      return cygwin_posix_to_win32_path_list (from, to);
-      break;
-    };
-  return -1;
-#endif /* USE_OLD_CYGWIN_CONV */
-}
-
-/* sleep function does not exist in mingw32 libraries. This is a
-   simple substitute function.  */
-#ifdef NEED_SLEEP_SUBSTITUTE
-int
-sleep (int t)
-{
-  /* Win32 API Sleep function accepts input time in milliseconds.  */
-  Sleep (t * 1000);
-  return t;
-}
-#endif /* NEED_SLEEP_SUBSTITUTE */
diff --git a/gdb/common/windows-hdep.h b/gdb/common/windows-hdep.h
deleted file mode 100644
index 29d99fb..0000000
--- a/gdb/common/windows-hdep.h
+++ /dev/null
@@ -1,134 +0,0 @@
-/* Copyright 2011 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
-
-/* The primary purpose of this file is to separate out
-   conversion between POSIX style and Windows NATIVE style
-   path and path lists.
-   For this purpose, generic replacement of the two cygwin function
-   cygwin_conv_path and cygwin_conv_path_list are created.  */
-
-#ifndef WINDOWS_HDEP_H
-#define WINDOWS_HDEP_H
-
-/* The following macros are redefined below depending on the use of wide
-   chars or not.  */
-#undef STARTUPINFO
-#undef CreateProcess
-#undef GetModuleFileNameEx
-#undef GetSystemDirectory
-/* Macro _G(text) either expands to simply text or to L##text depending
-   on use of wide chars or not.
-   Although this is similar to _T macro inside winnt.h header,
-   its value is set according to USE_WIDE_API macro, allowing to compile
-   GDB with wide char use even on systems for which the default is to
-   use ASCII chars.  */
-#undef _G
-
-#ifdef __CYGWIN__
-#ifdef PATH_MAX
-# define __PMAX	PATH_MAX
-#else
-# include <sys/param.h>
-# define __PMAX MAXPATHLEN
-#endif
-/*  For new Cygwin 1.7.X versions, use WIDE version of Windows API functions
-    by default, unless USE_ASCII_WINAPI is defined.
-    For older Cygwin 1.5.X versionsd, or for MingwXX systems, default to use
-    the Ansi versions.  */
-#include <sys/cygwin.h>
-#include <cygwin/version.h>
-# if CYGWIN_VERSION_DLL_MAKE_COMBINED(CYGWIN_VERSION_API_MAJOR,CYGWIN_VERSION_API_MINOR) >= 181
-#  define USE_NEW_CYGWIN_CONV
-#   ifndef USE_ASCII_WINAPI
-#     define USE_WIDE_WINAPI
-#   endif /* not USE_ASCII_WINAPI  */
-# else
-/*  For older 1.5.X Cygwin versions, use cygwin_onv_to_XXX functions
-    to emulate newer cygwin_conv_path function.  */
-#  define USE_OLD_CYGWIN_CONV
-#  define CW_SET_DOS_FILE_WARNING -1	/* no-op this for older Cygwin */
-# endif
-#else /* not __CYGWIN__ */
-# define __PMAX	(MAX_PATH + 1)
-# define USE_MINGW_CONV
-# define NEED_SLEEP_SUBSTITUTE
-#endif /* not __CYGWIN__ */
-
-#ifdef USE_WIDE_WINAPI
-# define _G(text) L##text
-# define _G_SUFFIX(text) (text "W")
-# define LPGSTR LPWSTR
-# define WINDOWS_POSIX_TO_NATIVE WINDOWS_POSIX_TO_NATIVE_W
-# define WINDOWS_NATIVE_TO_POSIX WINDOWS_NATIVE_W_TO_POSIX
-  typedef wchar_t win_buf_t;
-# define STARTUPINFO STARTUPINFOW
-# define CreateProcess CreateProcessW
-# define GetSystemDirectory GetSystemDirectoryW
-# define gdb_windows_strlen wstrlen
-# define gdb_windows_strcat wcscat
-/* Mingw has a special swprintf function without length argument.  */
-# ifndef __CYGWIN__
-#  define swprintf _snwprintf
-#endif
-#else /* not USE_WIDE_WINAPI */
-# define _G(text) text
-# define _G_SUFFIX(text) (text "A")
-# define LPGSTR LPSTR
-# define WINDOWS_POSIX_TO_NATIVE WINDOWS_POSIX_TO_NATIVE_A
-# define WINDOWS_NATIVE_TO_POSIX WINDOWS_NATIVE_A_TO_POSIX
-  typedef char win_buf_t;
-# define STARTUPINFO STARTUPINFOA
-# define CreateProcess CreateProcessA
-# define GetSystemDirectory GetSystemDirectoryA
-# define gdb_windows_strlen strlen
-# define gdb_windows_strcat strcat
-#endif /* not USE_WIDE_WINAPI */
-
-
-typedef enum
-{
-  WINDOWS_NATIVE_A_TO_POSIX = 1
-  ,WINDOWS_POSIX_TO_NATIVE_A = 2
-#ifdef USE_WIDE_WINAPI
-  ,WINDOWS_NATIVE_W_TO_POSIX = 3
-  ,WINDOWS_POSIX_TO_NATIVE_W = 4
-#endif
-  ,WINDOWS_NATIVE_TO_MSYS = 5
-} conv_type;
-
-/* GDB mapping to cygwin type cygwin_conv_path.
-   If SIZE is zero, return required size (in number of characters)
-   to store the converted string FROM.
-   if SIZE is non-zero, convert FROM according to OPER value,
-   respecting SIZE limit.
-   Returns size of converted string in characters or
-   -1 if there was an error.  */
-
-extern int gdb_win_conv_path (conv_type oper, const void *from,
-			      void * to, int size);
-
-/* Analogeous function for PATH style lists.  */
-
-extern int gdb_win_conv_path_list (conv_type oper, const void *from,
-				   void * to, int size);
-
-#ifdef NEED_SLEEP_SUBSTITUTE
-extern int sleep (int);
-#endif /* NEED_SLEEP_SUBSTITUTE */
-
-#endif /* WINDOWS_HDEP_H */
-
diff --git a/gdb/configure.host b/gdb/configure.host
index 86dd05a..bcebdaf 100644
--- a/gdb/configure.host
+++ b/gdb/configure.host
@@ -91,7 +91,7 @@ i[34567]86-*-netbsdelf* | i[34567]86-*-knetbsd*-gnu)
 i[34567]86-*-netbsd*)	gdb_host=nbsdaout ;;
 i[34567]86-*-go32*)	gdb_host=go32 ;;
 i[34567]86-*-mingw32*)	gdb_host=mingw
-			gdb_host_obs="mingw-hdep.o windows-hdep.o"
+			gdb_host_obs=mingw-hdep.o
 			;;
 i[34567]86-*-msdosdjgpp*) gdb_host=go32 ;;
 i[34567]86-*-linux*)	gdb_host=linux ;;
@@ -103,9 +103,7 @@ i[34567]86-*-openbsd*)	gdb_host=obsd ;;
 i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*)
 			gdb_host=sol2-64 ;;
 i[34567]86-*-solaris*)	gdb_host=i386sol2 ;;
-i[34567]86-*-cygwin*)	gdb_host=cygwin 
-			gdb_host_obs="posix-hdep.o windows-hdep.o"
-			;;
+i[34567]86-*-cygwin*)	gdb_host=cygwin ;;
 
 ia64-*-hpux*)		gdb_host=hpux ;;
 ia64-*-linux*)		gdb_host=linux ;;
@@ -176,7 +174,7 @@ x86_64-*-netbsd* | x86_64-*-knetbsd*-gnu)
 			gdb_host=nbsd64 ;;
 x86_64-*-openbsd*)	gdb_host=obsd64 ;;
 x86_64-*-mingw*)        gdb_host=mingw64
-			gdb_host_obs="mingw-hdep.o windows-hdep.o"
+			gdb_host_obs=mingw-hdep.o
 			;;
 m32r*-*-linux*)          gdb_host=linux ;;
 
diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in
index cc49260..1fabe59 100644
--- a/gdb/gdbserver/Makefile.in
+++ b/gdb/gdbserver/Makefile.in
@@ -335,8 +335,6 @@ server_h = $(srcdir)/server.h $(regcache_h) config.h $(srcdir)/target.h \
 		$(srcdir)/mem-break.h $(srcdir)/../common/gdb_signals.h \
 		$(signals_h)
 
-windows_hdep_h = $(srcdir)/../common/windows-hdep.h
-
 linux_low_h = $(srcdir)/linux-low.h
 
 lynx_low_h = $(srcdir)/lynx-low.h $(srcdir)/server.h
@@ -384,14 +382,9 @@ tracepoint.o: tracepoint.c $(server_h) $(srcdir)/../common/ax.def
 utils.o: utils.c $(server_h)
 gdbreplay.o: gdbreplay.c config.h
 
-# gdb/common/ dependencies
-
 signals.o: ../common/signals.c $(server_h) $(signals_def)
 	$(CC) -c $(CPPFLAGS) $(INTERNAL_CFLAGS) $< -DGDBSERVER
 
-windows-hdep.o: $(srcdir)/../common/windows-hdep.c $(windows_hdep_h)
-	${CC} -o windows-hdep.o -c -DGDBSERVER ${INTERNAL_CFLAGS} $<
-
 # We build memmem.c without -Werror because this file is not under
 # our control.  On LynxOS, the compiler generates some warnings
 # because str-two-way.h uses a constant (MAX_SIZE) whose definition
@@ -446,7 +439,6 @@ win32-low.o: win32-low.c $(win32_low_h) $(server_h) $(regdef_h) $(regcache_h)
 win32-arm-low.o: win32-arm-low.c $(win32_low_h) $(server_h)
 win32-i386-low.o: win32-i386-low.c $(win32_low_h) $(server_h) $(i386_low_h)
 
-
 spu-low.o: spu-low.c $(server_h)
 
 reg-arm.o : reg-arm.c $(regdef_h)
diff --git a/gdb/gdbserver/configure.srv b/gdb/gdbserver/configure.srv
index 00278db..d6110dd 100644
--- a/gdb/gdbserver/configure.srv
+++ b/gdb/gdbserver/configure.srv
@@ -60,7 +60,7 @@ case "${target}" in
 			srv_linux_thread_db=yes
 			;;
   arm*-*-mingw32ce*)	srv_regobj=reg-arm.o
-			srv_tgtobj="win32-low.o windows-hdep.o win32-arm-low.o"
+			srv_tgtobj="win32-low.o win32-arm-low.o"
 			srv_tgtobj="${srv_tgtobj} wincecompat.o"
 			# hostio_last_error implementation is in win32-low.c
 			srv_hostio_err_objs=""
@@ -83,7 +83,7 @@ case "${target}" in
 			srv_linux_thread_db=yes
 			;;
   i[34567]86-*-cygwin*)	srv_regobj="$srv_i386_regobj"
-			srv_tgtobj="i386-low.o win32-low.o windows-hdep.o win32-i386-low.o"


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-03-19 21:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-19 21:27 [SCM] master: * Undo last wrong patch muller

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).