diff --git a/components/libc/compilers/armlibc/sys/unistd.h b/components/libc/compilers/armlibc/sys/unistd.h index 73a73a267e052233f9236a88ef9aead01778f4f0..e1a1ad92f42e67e4bb9bc821cdda608f7af68e58 100644 --- a/components/libc/compilers/armlibc/sys/unistd.h +++ b/components/libc/compilers/armlibc/sys/unistd.h @@ -73,4 +73,7 @@ char * ttyname (int desc); unsigned int sleep(unsigned int seconds); int usleep(useconds_t usec); +uid_t getuid(void); +pid_t getpid(void); + #endif /* _SYS_UNISTD_H */ diff --git a/components/libc/compilers/common/unistd.c b/components/libc/compilers/common/unistd.c index 48e6beee4eea4ca63955e0f10332c53c306bcb72..c7ad654da70f97977d9b7d4f7980d46db25147a9 100644 --- a/components/libc/compilers/common/unistd.c +++ b/components/libc/compilers/common/unistd.c @@ -49,3 +49,15 @@ int usleep(useconds_t usec) return 0; } RTM_EXPORT(usleep); + +uid_t getuid(void) +{ + return -1; +} +RTM_EXPORT(getuid); + +pid_t getpid(void) +{ + return -1; +} +RTM_EXPORT(getuid); diff --git a/components/libc/compilers/dlib/sys/unistd.h b/components/libc/compilers/dlib/sys/unistd.h index 6d99cd6c55a48a7be4ae333c6b2ad4273536db0c..5ca56ad1360859fbe141971708a2bad7a45a2109 100644 --- a/components/libc/compilers/dlib/sys/unistd.h +++ b/components/libc/compilers/dlib/sys/unistd.h @@ -47,4 +47,7 @@ char * ttyname (int desc); unsigned int sleep(unsigned int seconds); int usleep(useconds_t usec); +uid_t getuid(void); +pid_t getpid(void); + #endif /* _SYS_UNISTD_H */