--- chicken_old.h Thu Apr 18 09:34:26 2013 +++ chicken.h Thu Apr 18 09:36:22 2013 @@ -87,7 +87,7 @@ # define C_NONUNIX #endif -#if defined(__sun__) && defined(__svr4__) +#if defined(__sun__) && defined(__svr4__) || defined(__SUNPRO_C) # define C_SOLARIS #endif @@ -918,6 +918,9 @@ # ifdef __linux__ extern double round(double); extern double trunc(double); +# elif defined (__SunOS_5_9) +static inline double trunc(double x) { return (x >= 0 ? floor(x) : floor(x) + 1); } +static inline double round(double x) { return (x - floor(x) >= 0.5 ? floor(x) + 1 : floor(x)); } # endif #else /* provide this file and define C_PROVIDE_LIBC_STUBS if you want to use