summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernard Xiong <[email protected]>2013-01-09 17:15:20 -0800
committerBernard Xiong <[email protected]>2013-01-09 17:15:20 -0800
commitc81fa554d995a1276ca0d21445a1f48e625d872a (patch)
tree07a85ab3c8ba594fc6308035822f3eaca0bfa5ad
parent1eb6e23c43e0271284425d065811c0802d749562 (diff)
parent1bb22a0a0b77370499a680a1fa4c964e1a10909b (diff)
Merge pull request #10 from grissiom/fix-math
fix math.h
-rw-r--r--components/libc/minilibc/math.c1
-rw-r--r--components/libc/minilibc/math.h9
2 files changed, 7 insertions, 3 deletions
diff --git a/components/libc/minilibc/math.c b/components/libc/minilibc/math.c
index bcba6051a8..27315a428c 100644
--- a/components/libc/minilibc/math.c
+++ b/components/libc/minilibc/math.c
@@ -9,7 +9,6 @@
*/
#define PRECISION 9
-#define M_PI 3.141592653589793238462643
static double cos_off_tbl[] = {0.0, -M_PI/2., 0, -M_PI/2.};
static double cos_sign_tbl[] = {1,-1,-1,1};
diff --git a/components/libc/minilibc/math.h b/components/libc/minilibc/math.h
index e2ce6f8e71..b436eb08b5 100644
--- a/components/libc/minilibc/math.h
+++ b/components/libc/minilibc/math.h
@@ -1,4 +1,9 @@
-#ifndef __STDIO_H__
-#define __STDIO_H__
+#ifndef __MATH_H__
+#define __MATH_H__
+
+#define M_PI 3.141592653589793238462643
+
+double sin(double x);
+double cos(double x);
#endif