Browse Source

libm: fix compile error

Fix a compile error when __UCLIBC_SUSV3_LEGACY__ is disabled.

Reported-by: Paolo Mantegazza <paolo.mantegazza@polimi.it>
Waldemar Brodkorb 6 years ago
parent
commit
7ebfbe2940
1 changed files with 4 additions and 5 deletions
  1. 4 5
      libm/w_scalb.c

+ 4 - 5
libm/w_scalb.c

@@ -19,6 +19,8 @@
 #include <math.h>
 #include "math_private.h"
 
+#if defined __UCLIBC_SUSV3_LEGACY__
+
 #if defined(__UCLIBC_HAS_FENV__)
 #include <errno.h>
 
@@ -42,11 +44,6 @@ sysv_scalb (double x, double fn)
 }
 #endif /* __UCLIBC_HAS_FENV__ */
 
-/* Here might be a check like "#if defined __UCLIBC_SUSV3_LEGACY__"
- * but because there is a sysv_scalb() func, it was decided
- * not to check yhis macro.
- */
-
 /* Wrapper scalb */
 double
 scalb (double x, double fn)
@@ -83,4 +80,6 @@ scalb (double x, double fn)
   return __ieee754_scalb (x, fn);
 #endif /* __UCLIBC_HAS_FENV__ */
 }
+
 libm_hidden_def(scalb)
+#endif