Article View: gnu.gcc.help
Article #53202Re: GCC2 patches for SCO UNIX
From: Chip Salzenberg
Date: Wed, 04 Mar 1992 21:35
Date: Wed, 04 Mar 1992 21:35
118 lines
3583 bytes
3583 bytes
Below are patches for GCC2 under SCO UNIX. The C++ problem was the
lack of crtbegin.o and crtend.o in the link command.
Index: config/x-i386sco
*************** INSTALL=cp
*** 2,5 ****
RANLIB = :
RANLIB_TEST = false
! CC = rcc -Di386
! OLDCC = rcc -Di386
--- 2,8 ----
RANLIB = :
RANLIB_TEST = false
! CC = rcc
! OLDCC = rcc
! RCCFLAGS = -Dunix -Di386 -DM_UNIX -DM_I386
! XCFLAGS = $(RCCFLAGS)
! CLIB = -lPW
Index: config/i386sco.h
***************
*** 5,8 ****
--- 5,9 ----
#include "i386v.h"
+ #undef CPP_SPEC
/* Use crt1.o as a startup file and crtn.o as a closing file. */
***************
*** 9,13 ****
#undef STARTFILE_SPEC
! #define STARTFILE_SPEC "%{pg:gcrt1.o%s}%{!pg:%{p:mcrt1.o%s}%{!p:crt1.o%s}}"
#define ENDFILE_SPEC "crtn.o%s"
--- 10,14 ----
#undef STARTFILE_SPEC
! #define STARTFILE_SPEC "%{pg:gcrt1.o%s}%{!pg:%{p:mcrt1.o%s}%{!p:crt1.o%s}} crtbegin.o%s"
#define ENDFILE_SPEC "crtn.o%s"
***************
*** 17,21 ****
#undef LIB_SPEC
#define LIB_SPEC \
! "%{p:-L/usr/lib/libp}%{pg:-L/usr/lib/libp} %{scointl:libintl.a%s} -lc"
/* Specify predefined symbols in preprocessor. */
--- 18,22 ----
#undef LIB_SPEC
#define LIB_SPEC \
! "%{p:-L/usr/lib/libp}%{pg:-L/usr/lib/libp} %{scointl:libintl.a%s} -lc crtend.o%s"
/* Specify predefined symbols in preprocessor. */
***************
*** 25,28 ****
--- 26,43 ----
#define CPP_SPEC "%{scointl:-DM_INTERNAT}"
+
+ /* caller has to pop the extra argument passed to functions that return
+ structures. */
+
+ #undef RETURN_POPS_ARGS
+ #define RETURN_POPS_ARGS(FUNTYPE,SIZE) \
+ (TREE_CODE (FUNTYPE) == IDENTIFIER_NODE ? 0 \
+ : (TARGET_RTD \
+ && (TYPE_ARG_TYPES (FUNTYPE) == 0 \
+ || (TREE_VALUE (tree_last (TYPE_ARG_TYPES (FUNTYPE))) \
+ == void_type_node))) ? (SIZE) \
+ : 0)
+ /* On other 386 systems, the last line looks like this:
+ : (aggregate_value_p (FUNTYPE)) ? GET_MODE_SIZE (Pmode) : 0) */
#if 0 /* Not yet certain whether this is needed. */
Index: config/i386.c
*************** function_epilogue (file, size)
*** 792,795 ****
--- 792,797 ----
output_asm_insn ("ret %1", xops);
}
+ #if 0
+ /* This code is obsolete, I think. --chip@tct.com */
else if (current_function_returns_struct)
{
*************** function_epilogue (file, size)
*** 797,800 ****
--- 799,803 ----
output_asm_insn ("ret %0", xops);
}
+ #endif
else
output_asm_insn ("ret", xops);
Index: gcc.1
*************** in the following sections.
*** 290,293 ****
--- 290,305 ----
\-msoft\-float
+ .I 80386 and 80486 Options
+ .br
+ \-m80387
+ \-msoft\-float
+ \-m486
+ \-mno486
+ \-m386
+ \-mrtd
+ \-mnortd
+ \-mregparm
+ \-mnoregparm
+
.I VAX Options
.br
--
Chip Salzenberg at Teltronics/TCT <chip@tct.com>, <73717.366@compuserve.com>
"Informix 4GL is not a 4G, and it's barely an L." -- John Tombs
Technical Details
Message-ID:
<m0lM3ch-0006wbC@tct.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!tct.COM!chipReferences:
<dan.699649656@dribble>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,dc80734069ef396b X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1992-03-04 22:49:14 PST Newsgroups: gnu.gcc.help Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!tct.COM!chip From: chip@tct.COM (Chip Salzenberg) Subject: Re: GCC2 patches for SCO UNIX Message-ID: <m0lM3ch-0006wbC@tct.com> Sender: daemon@cis.ohio-state.edu Organization: TC Telemanagement, Clearwater, FL References: <dan.699649656@dribble> Distribution: gnu Date: Wed, 4 Mar 1992 21:35:00 GMT Lines: 118