Browse Source

Guard matherr/__kernel_standard w/ _IEEE_LIBM, we do not use them, save 7,6k

Peter S. Mazinger 18 years ago
parent
commit
d48e59d980
4 changed files with 9 additions and 1 deletions
  1. 1 1
      libm/Makefile.in
  2. 3 0
      libm/k_standard.c
  3. 2 0
      libm/math_private.h
  4. 3 0
      libm/s_matherr.c

+ 1 - 1
libm/Makefile.in

@@ -21,7 +21,7 @@
 #
 
 CFLAGS-libm := -DNOT_IN_libc -DIS_IN_libm $(SSP_ALL_CFLAGS)
-CFLAGS-libm += -D_IEEE_LIBM -D_ISOC99_SOURCE -D_SVID_SOURCE
+CFLAGS-libm += -D_IEEE_LIBM
 
 LDFLAGS-libm.so := $(LDFLAGS)
 

+ 3 - 0
libm/k_standard.c

@@ -18,6 +18,8 @@ static char rcsid[] = "$NetBSD: k_standard.c,v 1.6 1995/05/10 20:46:35 jtc Exp $
 #include "math_private.h"
 #include <errno.h>
 
+#ifndef _IEEE_LIBM
+
 libm_hidden_proto(copysign)
 libm_hidden_proto(matherr)
 libm_hidden_proto(rint)
@@ -784,3 +786,4 @@ static double zero = 0.0;	/* used as const */
 	}
 	return exc.retval;
 }
+#endif /* _IEEE_LIBM */

+ 2 - 0
libm/math_private.h

@@ -186,7 +186,9 @@ extern double __ieee754_scalb (double,double) attribute_hidden;
 #endif
 
 /* fdlibm kernel function */
+#ifndef _IEEE_LIBM
 extern double __kernel_standard (double,double,int) attribute_hidden;
+#endif
 extern double __kernel_sin (double,double,int) attribute_hidden;
 extern double __kernel_cos (double,double) attribute_hidden;
 extern double __kernel_tan (double,double,int) attribute_hidden;

+ 3 - 0
libm/s_matherr.c

@@ -17,6 +17,8 @@ static char rcsid[] = "$NetBSD: s_matherr.c,v 1.6 1995/05/10 20:47:53 jtc Exp $"
 #include "math.h"
 #include "math_private.h"
 
+#ifndef _IEEE_LIBM
+
 libm_hidden_proto(matherr)
 #ifdef __STDC__
 	int matherr(struct exception *x)
@@ -30,3 +32,4 @@ libm_hidden_proto(matherr)
 	return n;
 }
 libm_hidden_def(matherr)
+#endif