diff --git a/configure.ac b/configure.ac index de1ac788..013d5185 100644 --- a/configure.ac +++ b/configure.ac @@ -236,6 +236,8 @@ case "$host_os" in [Compiling for Solaris platform]) AC_DEFINE_UNQUOTED([TS_CLASS], [1], [Prevent being scheduled RR]) + AC_DEFINE_UNQUOTED([_SEM_SEMUN_UNDEFINED], [1], + [The semun structure is undefined]) OS_CFLAGS="" OS_CPPFLAGS="-D_REENTRANT" OS_LDFLAGS="" diff --git a/exec/coroipcs.c b/exec/coroipcs.c index d960b9ef..9f7769e6 100644 --- a/exec/coroipcs.c +++ b/exec/coroipcs.c @@ -99,12 +99,14 @@ struct zcb_mapped { size_t size; }; +#if defined(_SEM_SEMUN_UNDEFINED) union semun { int val; struct semid_ds *buf; unsigned short int *array; struct seminfo *__buf; }; +#endif enum conn_state { CONN_STATE_THREAD_INACTIVE = 0, diff --git a/lib/coroipcc.c b/lib/coroipcc.c index 6d416089..c30fad7b 100644 --- a/lib/coroipcc.c +++ b/lib/coroipcc.c @@ -251,7 +251,7 @@ priv_change_send (struct ipc_instance *ipc_instance) return (0); } -#if !defined(semun) +#if defined(_SEM_SEMUN_UNDEFINED) union semun { int val; struct semid_ds *buf;