🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #52032

Re: gcc and xview

#52032
From: Joe Buck
Date: Tue, 16 Feb 1993 23:26
17 lines
1317 bytes
In article <1993Feb16.090409.7226@ucthpx.uct.ac.za> Greg@dip3.ee.uct.ac.za writes:
>I am having trouble using Xview 3.0 with gcc v.2.3.3.  Using the
>standard compiler (cc) my program compiles and runs, no problem.
>Compiling with gcc seems to work, but after the call to 'xv_init',
>there is a segmentation fault.  Is this a common problem with a simple
>fix?  Or should things be running smoothly and I'm screwing up?

By default, gcc has a different convention for passing structures by value
than Sun cc does.  If you are passing a structure by value from a
gcc-compiled routine to a cc-compiled routine, bad things may result.

The -fpcc-struct-return flag makes gcc do things the way the vendor's
compiler does.


--
Joe Buck	jbuck@ohm.berkeley.edu
Technical Details
Message-ID: <1lrt6v$bnc@agate.berkeley.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!agate!forney.berkeley.edu!jbuck
References: <1993Feb16.090409.7226@ucthpx.uct.ac.za>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,80e0fe0ac01cd3fe
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-02-16 15:26:23 PST
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!agate!forney.berkeley.edu!jbuck
From: jbuck@forney.berkeley.edu (Joe Buck)
Newsgroups: gnu.gcc.help
Subject: Re: gcc and xview
Date: 16 Feb 1993 23:26:23 GMT
Organization: U. C. Berkeley
Lines: 17
Message-ID: <1lrt6v$bnc@agate.berkeley.edu>
References: <1993Feb16.090409.7226@ucthpx.uct.ac.za>
NNTP-Posting-Host: forney.berkeley.edu