From: jeffc@soba.osf.org (Jeff Carter)
Subject: Re: Porting code problems
Date: 8 Apr 1994 17:50:58 GMT [thread overview]
Message-ID: <2o45i2$ffb@paperboy.osf.org> (raw)
In-Reply-To: 2o1arm$lbg@chaos.dac.neu.edu
In article <2o1arm$lbg@chaos.dac.neu.edu>, johnson@chaos.dac.neu.edu (Chris Johnson) writes:
> believe to be (but aren't sure) related to structures not being defined
> when I include them from /usr/include. The simplest example I have,
> which works fine with Ultrix, is the following.
>
> #include <sys/wait.h>
> main()
> { struct wait abd;
> }
>
> That compiler claims that the storage size for abc is unknown. There
> are other problem as well but this is one of them.
The 'union wait' is a Berkley-ism. If you want the "wait" family of interfaces
that use the union, compile as:
cc foo.c -D_BSD -lbsd
For code that came from Ultrix, this is probably the path of least resistance.
To make the code more portable, you can change to the POSIX.1 form (which is
an int, rather than a union) and the associated macros (WIF*, etc)
prev parent reply other threads:[~1994-04-08 17:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
1994-04-07 16:03 Porting code problems Chris Johnson
1994-04-07 16:42 ` System Janitor
1994-04-08 17:50 ` Jeff Carter [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox