mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-06 22:24:33 +02:00
newlib: don't use gcc-specific pragmas for clang
This commit is contained in:
@@ -79,8 +79,10 @@ ssize_t _write_r(struct _reent *r, int fd, const void * data, size_t size)
|
|||||||
* doesn't have the same signature as the original function.
|
* doesn't have the same signature as the original function.
|
||||||
* Disable type mismatch warnings for this reason.
|
* Disable type mismatch warnings for this reason.
|
||||||
*/
|
*/
|
||||||
|
#if defined(__GNUC__) && !defined(__clang__)
|
||||||
#pragma GCC diagnostic push
|
#pragma GCC diagnostic push
|
||||||
#pragma GCC diagnostic ignored "-Wattribute-alias"
|
#pragma GCC diagnostic ignored "-Wattribute-alias"
|
||||||
|
#endif
|
||||||
|
|
||||||
int _open_r(struct _reent *r, const char * path, int flags, int mode)
|
int _open_r(struct _reent *r, const char * path, int flags, int mode)
|
||||||
__attribute__((weak,alias("syscall_not_implemented")));
|
__attribute__((weak,alias("syscall_not_implemented")));
|
||||||
@@ -122,7 +124,9 @@ int _kill_r(struct _reent *r, int pid, int sig)
|
|||||||
void _exit(int __status)
|
void _exit(int __status)
|
||||||
__attribute__((alias("syscall_not_implemented_aborts")));
|
__attribute__((alias("syscall_not_implemented_aborts")));
|
||||||
|
|
||||||
|
#if defined(__GNUC__) && !defined(__clang__)
|
||||||
#pragma GCC diagnostic pop
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Replaces newlib fcntl, which has been compiled without HAVE_FCNTL */
|
/* Replaces newlib fcntl, which has been compiled without HAVE_FCNTL */
|
||||||
int fcntl(int fd, int cmd, ...)
|
int fcntl(int fd, int cmd, ...)
|
||||||
|
Reference in New Issue
Block a user