On Mar 5, 2008, at 11:38 AM, snowcrash+perl wrote:
On Wed, Mar 5, 2008 at 11:17 AM, Edward Moy <[EMAIL PROTECTED]> wrote:
Configure determines this by trying to compile:
----------- try.c -----------
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/sem.h>
int main () { union semun semun; semun.buf = 0; }
------------------------------
What happens when you try to compile the above program?
with
gcc --version
powerpc-apple-darwin9-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build
5531)
gcc -v try.c
looks ok to me,
(snip)
I forgot to mention that I'm still using the 4.0.1 compiler, while
it looks
like you're using the 4.2 compiler. If the above fails to compile
with 4.2,
you might try compiling try.c with 4.0.1 just to see if 4.2 has a bug
(though I would think this unlikely).
(snip)
looks effectively the same; only diff is:
GCC 4.2 -> ... --build=powerpc-apple-darwin9
--host=powerpc-apple-darwin9 --target=powerpc-apple-darwin9
GCC 4.0 -> ... --build=i686-apple-darwin9 ..
--host=powerpc-apple-darwin9 --target=powerpc-apple-darwin9
Well, it's a mystery. The only other thing I can think of is if
somehow _POSIX_C_SOURCE or _XOPEN_SOURCE are being defined when
Configure compiles try.c (and union semun would not be defined in sys/
sem.h as per POSIX), but when miniperlmain.c compiles, those macros
aren't defined, so union semun is visible in sys/sem.h, but by that
time HAS_UNION_SEMUN has been define, so union semun gets redefined.
--------------------------------------------------------------------------
Edward Moy
Apple Inc.
[EMAIL PROTECTED]