mbed_retarget: enable IAR build

pull/14935/head
Jerome Coutant 2021-07-19 15:05:37 +02:00
parent d147abc3e5
commit e61aff6564
1 changed files with 8 additions and 1 deletions

View File

@ -37,7 +37,7 @@
#endif #endif
#include <errno.h> #include <errno.h>
#if !defined(__ARMCC_VERSION) #if !defined(__ARMCC_VERSION) && defined(__GNUC__)
#include <fcntl.h> #include <fcntl.h>
#endif #endif
@ -468,9 +468,16 @@ typedef struct DIR_impl DIR;
#ifndef ELIBEXEC #ifndef ELIBEXEC
#define ELIBEXEC 83 /* Cannot exec a shared library directly */ #define ELIBEXEC 83 /* Cannot exec a shared library directly */
#endif #endif
#if defined ( __ICCARM__ )
#undef EILSEQ /* defined in IAR arm/inc/c/errno.h: #define EILSEQ 36 */
#define EILSEQ 84 /* Illegal byte sequence */
#else
#ifndef EILSEQ #ifndef EILSEQ
#define EILSEQ 84 /* Illegal byte sequence */ #define EILSEQ 84 /* Illegal byte sequence */
#endif #endif
#endif
#ifndef ERESTART #ifndef ERESTART
#define ERESTART 285 /* Interrupted system call should be restarted */ #define ERESTART 285 /* Interrupted system call should be restarted */
#endif #endif