Browse Source

[kernel] fix MUSL libc issue in errno.h

BernardXiong 4 years ago
parent
commit
e2e4090228
1 changed files with 2 additions and 2 deletions
  1. 2 2
      include/libc/libc_errno.h

+ 2 - 2
include/libc/libc_errno.h

@@ -13,7 +13,7 @@
 
 #include <rtconfig.h>
 
-#if defined(RT_USING_NEWLIB) || defined(_WIN32) || defined(__ARMCC_GNUC__)
+#if defined(RT_USING_NEWLIB) || defined(RT_USING_MUSL) || defined(_WIN32) || defined(__ARMCC_GNUC__)
 /* use errno.h file in toolchains */
 #include <errno.h>
 #endif
@@ -45,7 +45,7 @@ defined in armcc/errno.h
 #define ERROR_BASE_NO    0
 #endif
 
-#if !defined(RT_USING_NEWLIB) && !defined(_WIN32) && !defined(__ARMCC_GNUC__)
+#if !defined(RT_USING_NEWLIB) && !defined(RT_USING_MUSL) && !defined(_WIN32) && !defined(__ARMCC_GNUC__)
 
 #define EPERM            (ERROR_BASE_NO + 1)
 #define ENOENT           (ERROR_BASE_NO + 2)