00001 // Weak replacement for the *rand48 family of functions which are unavailable 00002 // on non-Cygwin Windows builds. For use in examples only. 00003 00004 #if !defined(RAND48_REPLACEMENT_H) 00005 #define RAND48_REPLACEMENT_H 00006 00007 #if defined(_WIN32) 00008 00009 #include <stdlib.h> 00010 #define srand48(x) srand(x) 00011 #define drand48() (((double)rand())/RAND_MAX) 00012 00013 #endif 00014 00015 #endif