diff --git a/ChangeLog b/ChangeLog index 0eda7f709..5b7407f7a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2006-01-27 Eric Anholt + + * hw/xfree86/os-support/shared/libc_wrapper.c: (xf86random): + * hw/xfree86/os-support/xf86_ansic.h: + * hw/xfree86/os-support/xf86_libc.h: + Add libc_wrapper support for random(), which will be used in upcoming + EXA memory manager work. + 2006-01-27 Eric Anholt * hw/xfree86/dixmods/Makefile.am: diff --git a/hw/xfree86/os-support/shared/libc_wrapper.c b/hw/xfree86/os-support/shared/libc_wrapper.c index 4bd17914c..346915885 100644 --- a/hw/xfree86/os-support/shared/libc_wrapper.c +++ b/hw/xfree86/os-support/shared/libc_wrapper.c @@ -2148,3 +2148,8 @@ xf86setjmperror(xf86jmp_buf env) xf86getjmptype()); } +long +xf86random() +{ + return random(); +} diff --git a/hw/xfree86/os-support/xf86_ansic.h b/hw/xfree86/os-support/xf86_ansic.h index c4090dc16..25dabfe89 100644 --- a/hw/xfree86/os-support/xf86_ansic.h +++ b/hw/xfree86/os-support/xf86_ansic.h @@ -218,6 +218,7 @@ extern double xf86pow(double,double); extern void xf86qsort(void*, xf86size_t, xf86size_t, int(*)(const void*, const void*)); extern void* xf86realloc(void*,xf86size_t); +extern long xf86random(void); extern int xf86remove(const char*); extern int xf86rename(const char*,const char*); extern void xf86rewind(XF86FILE*); diff --git a/hw/xfree86/os-support/xf86_libc.h b/hw/xfree86/os-support/xf86_libc.h index 5f0f78f02..5a6056ba9 100644 --- a/hw/xfree86/os-support/xf86_libc.h +++ b/hw/xfree86/os-support/xf86_libc.h @@ -1,4 +1,4 @@ -/* $XdotOrg: xc/programs/Xserver/hw/xfree86/os-support/xf86_libc.h,v 1.6 2005/04/22 22:04:37 alanc Exp $ */ +/* $XdotOrg: xserver/xorg/hw/xfree86/os-support/xf86_libc.h,v 1.9 2005/08/24 11:18:31 daniels Exp $ */ /* $XFree86: xc/programs/Xserver/hw/xfree86/os-support/xf86_libc.h,v 3.63 2003/12/08 21:46:55 alanh Exp $ */ /* * Copyright (c) 1997-2003 by The XFree86 Project, Inc. @@ -358,6 +358,8 @@ typedef int xf86jmp_buf[1024]; #define perror(ccp) xf86perror(ccp) #undef pow #define pow(d1,d2) xf86pow(d1,d2) +#undef random +#define random() xf86random() #undef realloc #define realloc(vp,I) xf86realloc(vp,I) #undef remove