public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
@ 2003-02-14 23:56 william
  0 siblings, 0 replies; 5+ messages in thread
From: william @ 2003-02-14 23:56 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR target/9603; it has been noted by GNATS.

From: william@nscs.fast.net
To: florent.pillet@wanadoo.fr
Cc: gcc-gnats@gcc.gnu.org, gcc-bugs@gcc.gnu.org, nobody@gcc.gnu.org, 
    gcc-prs@gcc.gnu.org
Subject: Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
Date: Fri, 14 Feb 2003 18:52:15 EST

 I think that the problem was due using DEFAULT_PCC_STRUCT_RETURN in
 an os-independent file (i386.c) and not supplying definitions in all of
 the os-dependent places that use it.  SCO OpenServer is Pentium-based.
 I submitted a patch for the SCO-specific header sco5.h.
   http://gcc.gnu.org/ml/gcc-bugs/2003-02/msg00300.html
 Someone else who had this problem with Solaris/Intel
 submitted a patch for i386.h.  I think that most i386 builds
 eventually include i386.h eventually.
   http://gcc.gnu.org/ml/gcc-bugs/2003-02/msg00282.html  
 I think that the each operating system needs a separate patch
 in its os-specific header because the value of the macro depends
 on the operating system specific rules on whether functions can
 return structures and unions in registers instead of memory.
 It is possible that iBCS2 defines this and applies to all i386
 environments, so one value might work for everything.
 It is my theory that changes like this are someone's subtle
 method of finding out which build targets can be deprecated...
 Good luck with your Darwin-hosted i386 cross-compile!
 It sounds painful -- I'm afraid to ask why you need to do it.
 William
 http://williambader.com


^ permalink raw reply	[flat|nested] 5+ messages in thread
* Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
@ 2003-03-29 10:36 ebotcazou
  0 siblings, 0 replies; 5+ messages in thread
From: ebotcazou @ 2003-03-29 10:36 UTC (permalink / raw)
  To: gcc-bugs, gcc-prs, nobody, william

Synopsis: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN

State-Changed-From-To: open->closed
State-Changed-By: ebotcazou
State-Changed-When: Sat Mar 29 09:51:42 2003
State-Changed-Why:
    Duplicate of PR other/9638.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9603


^ permalink raw reply	[flat|nested] 5+ messages in thread
* Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
@ 2003-02-26 14:36 John Hughes
  0 siblings, 0 replies; 5+ messages in thread
From: John Hughes @ 2003-02-26 14:36 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR target/9603; it has been noted by GNATS.

From: "John Hughes" <john@Calva.COM>
To: <gcc-gnats@gcc.gnu.org>, <gcc-bugs@gcc.gnu.org>, <nobody@gcc.gnu.org>,
   <william@nscs.fast.net>, <gcc-prs@gcc.gnu.org>
Cc: <michaud.bernard@ic.gc.ca>
Subject: Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
Date: Wed, 26 Feb 2003 15:32:50 +0100

 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=g
 cc&pr=9603
 
 and
 
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=g
 cc&pr=9583 
 
 This bug is also present on UnixWare 7.1.1 (aka svr5) and
 I'd guess all other versions of svr4.
 
 It's still present in the 2003/02/24 snapshot of 3.3.
 
 For svr4 systems the fix is:
 
 --- gcc-20030224/gcc/config/i386/sysv4.h.orig   Sun Jun 16 23:13:11 2002
 +++ gcc-20030224/gcc/config/i386/sysv4.h        Wed Feb 26 14:35:08 2003
 @@ -23,6 +23,14 @@
  
  #define TARGET_VERSION fprintf (stderr, " (i386 System V Release 4)");
  
 +#if 0
 +
 +/* i386.h says:
 +
 +   Do not use this macro to indicate that structures and unions
 +   should always be returned in memory.  You should instead use
 +   `DEFAULT_PCC_STRUCT_RETURN' to indicate this.  */
 +
  /* The svr4 ABI for the i386 says that records and unions are returned
     in memory.  */
  
 @@ -30,6 +38,12 @@
  #define RETURN_IN_MEMORY(TYPE) \
    (TYPE_MODE (TYPE) == BLKmode \
     || (VECTOR_MODE_P (TYPE_MODE (TYPE)) && int_size_in_bytes (TYPE) ==
 8))
 +
 +#else
 +
 +#define DEFAULT_PCC_STRUCT_RETURN 1
 +
 +#endif
  
  /* Output at beginning of assembler file.  */
  /* The .file command should always begin the output.  */
 


^ permalink raw reply	[flat|nested] 5+ messages in thread
* Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
@ 2003-02-14 23:26 Florent Pillet
  0 siblings, 0 replies; 5+ messages in thread
From: Florent Pillet @ 2003-02-14 23:26 UTC (permalink / raw)
  To: nobody; +Cc: gcc-prs

The following reply was made to PR target/9603; it has been noted by GNATS.

From: Florent Pillet <florent.pillet@wanadoo.fr>
To: gcc-gnats@gcc.gnu.org,
 gcc-bugs@gcc.gnu.org,
 nobody@gcc.gnu.org,
 william@nscs.fast.net,
 gcc-prs@gcc.gnu.org
Cc:  
Subject: Re: target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
Date: Sat, 15 Feb 2003 00:24:42 +0100

 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit- 
 trail&database=gcc&pr=9603
 
 This problem also occurs when cross-compiling a gcc 3.2.2 with  
 --target=i386 and --target=i486 on Mac OS X. In other words, it is not  
 a problem specific to the sco platform.
 
 Platform: powerpc-apple-darwin6.2
 OS: Mac OS X 10.2.4
 Compiler: gcc (GCC) 3.1 20020420 (prerelease)
 
 (/Volumes/UnixTools/src/gcc-3.2.2-build)% cat config.status
 #!/bin/sh
 # This file was generated automatically by configure.  Do not edit.
 # This directory was configured as follows:
 ../gcc-3.2.2/configure  
 --with-gcc-version-trigger=/Volumes/UnixTools/src/gcc-3.2.2/gcc/ 
 version.c --host=powerpc-apple-darwin6.2 --enable-languages=c,c++  
 --target=i486-elf --prefix=/usr/local --norecursion
 #
 
 -- 
 Florent Pillet, Code Segment       florent.pillet@wanadoo.fr
 Developer tools and end-user products         ICQ: 117292463
 Palm, Mac, Unix, Windows     http://perso.wanadoo.fr/fpillet
 


^ permalink raw reply	[flat|nested] 5+ messages in thread
* target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
@ 2003-02-06 21:26 william
  0 siblings, 0 replies; 5+ messages in thread
From: william @ 2003-02-06 21:26 UTC (permalink / raw)
  To: gcc-gnats


>Number:         9603
>Category:       target
>Synopsis:       SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Feb 06 21:26:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     william@nscs.fast.net
>Release:        gcc-3.2.2
>Organization:
>Environment:
SCO OpenServer 5.0.5 with SCO's development system
>Description:
I got
  "i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN"
when building gcc-3.2.2 under SCO OpenServer 5.0.5 using SCO's dev sys.
The patch included in the "Fix" section fixes the problem
through a #define of DEFAULT_PCC_STRUCT_RETURN in sco5.h.
I was not sure whether to set it to 0 or 1, but gcc-3.2.1 has a "1"
in i386.cc where gcc-3.2.2 has "DEFAULT_PCC_STRUCT_RETURN".

William Bader
http://williambader.com
>How-To-Repeat:

>Fix:
diff -rN -U 8 -X bgcc-3.2.2/gcc/bounds/diffexclude.dat gcc-3.2.2/gcc/config/i386/sco5.h bgcc-3.2.2/gcc/config/i386/sco5.h
--- gcc-3.2.2/gcc/config/i386/sco5.h    2002-04-24 13:18:04.000000000 -0400
+++ bgcc-3.2.2/gcc/config/i386/sco5.h   2003-02-06 13:52:41.000000000 -0500
@@ -723,16 +723,20 @@
          %{fPIC:%{!fpic:-D__PIC__ -D__pic__}}} \
   %{Xa:-D_SCO_C_DIALECT=1} \
   %{!Xa:%{Xc:-D_SCO_C_DIALECT=3} \
    %{!Xc:%{Xk:-D_SCO_C_DIALECT=4} \
     %{!Xk:%{Xt:-D_SCO_C_DIALECT=2} \
      %{!Xt:-D_SCO_C_DIALECT=1}}}} \
   %{traditional:-traditional -D_KR -D_NO_PROTOTYPE}"
 
+/* The svr4 ABI for the i386 says that records and unions are returned in memory.  */
+#undef DEFAULT_PCC_STRUCT_RETURN
+#define DEFAULT_PCC_STRUCT_RETURN 1
+
 #undef LINK_SPEC
 #define LINK_SPEC \
  "-b %{!mcoff:elf}%{mcoff:coff \
    %{static:%e-static not valid with -mcoff} \
    %{shared:%e-shared not valid with -mcoff} \
    %{symbolic:%e-symbolic not valid with -mcoff} \
    %{fpic:%e-fpic not valid with -mcoff} \
    %{fPIC:%e-fPIC not valid with -mcoff}} \
>Release-Note:
>Audit-Trail:
>Unformatted:


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

end of thread, other threads:[~2003-03-29  9:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-02-14 23:56 target/9603: SCO 5 build of gcc-3.2.2 fails with i386.c: line 927: error: undefined symbol: DEFAULT_PCC_STRUCT_RETURN william
  -- strict thread matches above, loose matches on Subject: below --
2003-03-29 10:36 ebotcazou
2003-02-26 14:36 John Hughes
2003-02-14 23:26 Florent Pillet
2003-02-06 21:26 william

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