From 29217abb05037fd78a4b72d4acb5a44dee97b9ad Mon Sep 17 00:00:00 2001 From: stpohle Date: Thu, 11 Sep 2003 19:44:31 +0000 Subject: [PATCH] Solaris Patch - by pak21@users.sourceforge.net --- configure.in | 4 ++++ src/sysfunc.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/configure.in b/configure.in index e538307..76632b6 100644 --- a/configure.in +++ b/configure.in @@ -44,6 +44,10 @@ case "$target" in CFLAGS="$CFLAGS" LIBS="$LIBS -liberty -lwsock32" ;; + *solaris* ) + CFLAGS="$CFLAGS" + LIBS="$LIBS -lsocket -lnsl -lm" + ;; esac CFLAGS="$CFLAGS -Wall" diff --git a/src/sysfunc.c b/src/sysfunc.c index 3828c87..988c1a0 100644 --- a/src/sysfunc.c +++ b/src/sysfunc.c @@ -1,4 +1,4 @@ -/* $Id: sysfunc.c,v 1.18 2003/09/10 21:32:22 stpohle Exp $ +/* $Id: sysfunc.c,v 1.19 2003/09/11 19:44:32 stpohle Exp $ sysfunc.c - this file hold some routines for the system functions.. like d_delay */ @@ -30,7 +30,7 @@ s_delay (int ms) int s_random (int maxnr) { -#ifdef _WIN32 +#if ( defined _WIN32 ) || ( RAND_MAX < 2147483647UL ) return ((rand () * maxnr) / RAND_MAX); #else int i;