summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRandom06457 <28494085+Random06457@users.noreply.github.com>2023-11-19 20:52:00 +0100
committerRandom06457 <28494085+Random06457@users.noreply.github.com>2023-11-19 20:52:00 +0100
commit9cc6c79f26e8ba386d684126d1797e4df51d1f9d (patch)
tree90e9e4fd1226d70be84c9c2cfe63469bdf3b73db
parent46cab74a9ce1daa94efed7c86a51b03a8133877a (diff)
fix __GNUC__ related issues
-rw-r--r--mm/include/command_macros_base.h4
-rw-r--r--mm/include/libc/math.h10
2 files changed, 6 insertions, 8 deletions
diff --git a/mm/include/command_macros_base.h b/mm/include/command_macros_base.h
index 4a866c29e..a52ee1667 100644
--- a/mm/include/command_macros_base.h
+++ b/mm/include/command_macros_base.h
@@ -16,11 +16,7 @@
#define CMD_W(a) (a)
-#ifdef __GNUC__
-#define CMD_F(a) .f = (a)
-#else
#define CMD_F(a) (a)
-#endif
#define CMD_PTR(a) (uintptr_t)(a)
diff --git a/mm/include/libc/math.h b/mm/include/libc/math.h
index 3f5ed3a20..57ea1d81e 100644
--- a/mm/include/libc/math.h
+++ b/mm/include/libc/math.h
@@ -1,16 +1,16 @@
#ifndef LIBC_MATH_H
#define LIBC_MATH_H
-#include "PR/ultratypes.h"
-
#define M_PI 3.14159265358979323846f
#define M_SQRT2 1.41421356237309504880f
-#define M_SQRT3 1.7320508075688772935274463415059f
-#define M_SQRT1_2 0.70710678118654752440f /* 1/sqrt(2) */
+#define M_SQRT1_2 0.70710678118654752440f /* 1/sqrt(2) */
#define FLT_MAX 340282346638528859811704183484516925440.0f
#define SHT_MAX 32767.0f
#define SHT_MINV (1.0f / SHT_MAX)
+#ifdef __GNUC__
+#include <math.h>
+#else
float fabsf(float f);
#pragma intrinsic(fabsf)
#ifdef __GNUC__
@@ -21,3 +21,5 @@ double sqrt(double d);
#pragma intrinsic(sqrt)
#endif
+
+#endif