CC 5.8 Compile error

this is the compile command and works fine on sunos 5.8 using gcc - what am i missing here?

CC -D_POSIX_C_SOURCE=199506L -DUSE_DML_INF -DNDEBUG -DSUN_CC_HAS_PVFC_BUG -D_POSIX_PTHREAD_SEMANTICS -I/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version -mt -g -KPIC -I../inc -I/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version -I../../ -I/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/Include -I/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE _wrappers -I/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/Src/Infrastructure-o ProcessInfo.o.sun10 -c ProcessInfo.cpp

"/usr/include/sys/ucontext.h", line 69: Error: Type name expected instead of "stack_t".

"/usr/include/ucontext.h", line 49: Error: stack_t is not defined.

"/usr/include/ucontext.h", line 50: Error: stack_t is not defined.

"/usr/include/ucontext.h", line 52: Error: stack_t is not defined.

"/usr/include/ucontext.h", line 53: Error: ")" expected instead of "*".

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/os_include/os_unistd.h", line 103: Error: u_int is not defined.

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/os_include/os_unistd.h", line 103: Error: u_int is not defined.

"/usr/include/sys/resource.h", line 146: Error: In this declaration "ru_utime" is of an incomplete type "timeval".

"/usr/include/sys/resource.h", line 147: Error: In this declaration "ru_stime" is of an incomplete type "timeval".

"/usr/include/sys/old_procfs.h", line 142: Error: In this declaration "pr_altstack" is of an incomplete type "sigaltstack".

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/os_include/os_stdlib.h", line 58: Error: u_int is not defined.

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/OS_NS_wchar.h", line 166: Error: u_int is not defined.

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/OS_NS_wchar.inl", line 20: Error: u_int is not defined.

"/users/fv8_dev/PROJ_DVP/FRAUDSERVER/Latest_Version/../3rd_party/ACE-5.5.0/ACE_ wrappers/ace/OS_NS_wchar.inl", line 23: Error: u_int is not defined.

[2321 byte] By [eyalzm] at [2007-11-26 8:28:49]
# 1

> this is the compile command and works fine on sunos

> 5.8 using gcc - what am i missing here?

> "/usr/include/sys/ucontext.h", line 69: Error: Type

> name expected instead of "stack_t".

Looks like you're missing stack_t

Try including signal.h

Paul

Paul_Floyd at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 2
<signal.h> is already included
eyalzm at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 3
Try defining _XPG4_2, but its definitely a hack.
MaximKartashev at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 4
The problem is that defining -D_POSIX_C_SOURCE=199506L disables some of the declarations your program needs.Why do you need that macro defintiion? If you don't know why it's needed, try removing it.
clamage45 at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 5
i use posix and that declaration is used with posix
eyalzm at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 6
i'll remove it and check if all is ok
eyalzm at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...
# 7
-D__EXTENSIONS__ - does the work
eyalzm at 2007-7-6 21:46:28 > top of Java-index,Development Tools,Solaris and Linux Development Tools...