[PATCH] Fix cygwin bootstrap failure
Roger Sayle
roger@www.eyesopen.com
Thu Feb 27 01:43:00 GMT 2003
On Wed, 26 Feb 2003, Richard Henderson wrote:
> On Tue, Feb 25, 2003 at 10:58:51PM -0700, Roger Sayle wrote:
> > * config/i386/cygwin.h: Don't directly include i386/i386.h.
> > * config.gcc (cygwin, mingw32, uwin): Retain i386/i386.h in
> > tm_files.
>
> This is correct. I would prefer that you went farther
> and removed *all* of the includes from cygwin.h.
How about the following?
This patch has been tested with a full bootstrap on i686-pc-cygwin,
all languages except Ada and treelang.
Ok for mainline?
2003-02-26 Roger Sayle <roger@eyesopen.com>
* config/i386/cygwin.h: Don't include any other files directly.
* config/i386/mingw32.h: Don't include cygwin.h directly.
* config.gcc (cygwin, mingw32, uwin): Instead make these files
explicit in the tm_files variable.
Index: config.gcc
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config.gcc,v
retrieving revision 1.285
diff -c -3 -p -r1.285 config.gcc
*** config.gcc 26 Feb 2003 19:28:37 -0000 1.285
--- config.gcc 26 Feb 2003 23:15:25 -0000
*************** i[34567]86-*-pe | i[34567]86-*-cygwin*)
*** 1312,1318 ****
xm_defines=POSIX
xm_file=i386/xm-cygwin.h
tmake_file=i386/t-cygwin
! tm_file=i386/cygwin.h
extra_objs=winnt.o
if test x$enable_threads = xyes; then
thread_file='win32'
--- 1312,1318 ----
xm_defines=POSIX
xm_file=i386/xm-cygwin.h
tmake_file=i386/t-cygwin
! tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygwin.h"
extra_objs=winnt.o
if test x$enable_threads = xyes; then
thread_file='win32'
*************** i[34567]86-*-pe | i[34567]86-*-cygwin*)
*** 1320,1326 ****
exeext=.exe
;;
i[34567]86-*-mingw32*)
! tm_file=i386/mingw32.h
xm_defines=POSIX
xm_file=i386/xm-mingw32.h
tmake_file="i386/t-cygwin i386/t-mingw32"
--- 1320,1326 ----
exeext=.exe
;;
i[34567]86-*-mingw32*)
! tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygwin.h i386/mingw32.h"
xm_defines=POSIX
xm_file=i386/xm-mingw32.h
tmake_file="i386/t-cygwin i386/t-mingw32"
*************** i[34567]86-*-mingw32*)
*** 1338,1344 ****
esac
;;
i[34567]86-*-uwin*)
! tm_file="i386/cygwin.h i386/uwin.h"
tmake_file="i386/t-cygwin i386/t-uwin"
extra_objs=winnt.o
if test x$enable_threads = xyes; then
--- 1338,1344 ----
esac
;;
i[34567]86-*-uwin*)
! tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygwin.h i386/uwin.h"
tmake_file="i386/t-cygwin i386/t-uwin"
extra_objs=winnt.o
if test x$enable_threads = xyes; then
Index: config/i386/cygwin.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/i386/cygwin.h,v
retrieving revision 1.80
diff -c -3 -p -r1.80 cygwin.h
*** config/i386/cygwin.h 16 Feb 2003 06:27:19 -0000 1.80
--- config/i386/cygwin.h 26 Feb 2003 23:15:25 -0000
*************** Boston, MA 02111-1307, USA. */
*** 22,38 ****
#define DBX_DEBUGGING_INFO 1
#define SDB_DEBUGGING_INFO 1
#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
#define TARGET_VERSION fprintf (stderr, " (x86 Cygwin)");
#define TARGET_EXECUTABLE_SUFFIX ".exe"
#include <stdio.h>
- #include "i386/i386.h"
- #include "i386/unix.h"
- #include "i386/bsd.h"
- #include "i386/gas.h"
- #include "dbxcoff.h"
/* Masks for subtarget switches used by other files. */
#define MASK_NOP_FUN_DLLIMPORT 0x08000000 /* Ignore dllimport for functions */
--- 22,35 ----
#define DBX_DEBUGGING_INFO 1
#define SDB_DEBUGGING_INFO 1
+
+ #undef PREFERRED_DEBUGGING_TYPE
#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
#define TARGET_VERSION fprintf (stderr, " (x86 Cygwin)");
#define TARGET_EXECUTABLE_SUFFIX ".exe"
#include <stdio.h>
/* Masks for subtarget switches used by other files. */
#define MASK_NOP_FUN_DLLIMPORT 0x08000000 /* Ignore dllimport for functions */
Index: config/i386/mingw32.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/i386/mingw32.h,v
retrieving revision 1.31
diff -c -3 -p -r1.31 mingw32.h
*** config/i386/mingw32.h 15 Feb 2003 04:58:22 -0000 1.31
--- config/i386/mingw32.h 26 Feb 2003 23:15:25 -0000
*************** Boston, MA 02111-1307, USA. */
*** 29,36 ****
#define WIN32_NO_ABSOLUTE_INST_DIRS 1
#endif
- #include "i386/cygwin.h"
-
#define TARGET_EXECUTABLE_SUFFIX ".exe"
/* See i386/crtdll.h for an alternative definition. */
--- 29,34 ----
Roger
--
Roger Sayle, E-mail: roger@eyesopen.com
OpenEye Scientific Software, WWW: http://www.eyesopen.com/
Suite 1107, 3600 Cerrillos Road, Tel: (+1) 505-473-7385
Santa Fe, New Mexico, 87507. Fax: (+1) 505-473-0833
More information about the Gcc-patches
mailing list