f60f0f22f9f518668117622eb89a7f19f06fdd2e
[openwrt/svn-archive/archive.git] / libs / postgresql / patches / 850-uclibc_no_cbrt.patch
1 Index: postgresql-8.3.0/src/backend/utils/adt/float.c
2 ===================================================================
3 --- postgresql-8.3.0.orig/src/backend/utils/adt/float.c 2008-01-01 13:45:52.000000000 -0600
4 +++ postgresql-8.3.0/src/backend/utils/adt/float.c 2008-02-06 16:30:02.000000000 -0600
5 @@ -71,7 +71,9 @@
6 static int float8_cmp_internal(float8 a, float8 b);
7
8 #ifndef HAVE_CBRT
9 -static double cbrt(double x);
10 +#undef cbrt
11 +#define cbrt(x) pg_cbrt(x)
12 +static double pg_cbrt(double x);
13 #endif /* HAVE_CBRT */
14
15
16 @@ -2733,7 +2735,7 @@
17 #ifndef HAVE_CBRT
18
19 static double
20 -cbrt(double x)
21 +pg_cbrt(double x)
22 {
23 int isneg = (x < 0.0);
24 double absx = fabs(x);