diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/libc-internal.h | 4 | ||||
-rw-r--r-- | include/ssp-internal.h | 83 | ||||
-rw-r--r-- | include/string.h | 4 |
3 files changed, 8 insertions, 83 deletions
diff --git a/include/libc-internal.h b/include/libc-internal.h index 11e020ee1..9694dc9bd 100644 --- a/include/libc-internal.h +++ b/include/libc-internal.h @@ -155,6 +155,10 @@ extern char *__strdup (__const char *__s) attribute_hidden; extern ssize_t __read(int __fd, void *__buf, size_t __nbytes) attribute_hidden; extern ssize_t __write(int __fd, __const void *__buf, size_t __n) attribute_hidden; extern int __close(int __fd) attribute_hidden; +extern __pid_t __getpid (void) attribute_hidden; + +/* #include <stdlib.h> */ +extern char *__getenv (__const char *__name) attribute_hidden; /* #include <signal.h> */ extern int __sigprocmask (int __how, __const __sigset_t *__restrict __set, diff --git a/include/ssp-internal.h b/include/ssp-internal.h deleted file mode 100644 index cd44b4f5d..000000000 --- a/include/ssp-internal.h +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Distributed under the terms of the GNU Lesser General Public License - * $Header: $ - */ - -#ifndef _SSP_INTERNAL_H -#define _SSP_INTERNAL_H 1 - -#ifdef __SSP__ -#error "file must not be compiled with stack protection enabled on it. Use -fno-stack-protector" -#endif - -#ifdef __PROPOLICE_BLOCK_SEGV__ -# define SSP_SIGTYPE SIGSEGV -#else -# define SSP_SIGTYPE SIGABRT -#endif - -#include <sys/types.h> -#include <sys/time.h> -#include <signal.h> -#include <linux/unistd.h> - -#ifndef errno -extern int errno; -#endif - -#ifndef __SSP_QUICK_CANARY__ -#define __NR___kernel_open __NR_open -static __always_inline _syscall3(int,__kernel_open,const char *,path,int,flags,__kernel_mode_t,mode); -#define OPEN(path, flags, mode) __kernel_open(path, flags, mode) - -/* void * = __ptr_t */ -#define __NR___kernel_read __NR_read -static __always_inline _syscall3(ssize_t,__kernel_read,int,fd,void *,buf,size_t,count); -#define READ(fd, buf, count) __kernel_read(fd, buf, count) - -#define __NR___kernel_close __NR_close -static __always_inline _syscall1(int,__kernel_close,int,fd); -#define CLOSE(fd) __kernel_close(fd) -#endif - -/* const void * = const __ptr_t */ -#define __NR___kernel_write __NR_write -static __always_inline _syscall3(ssize_t,__kernel_write,int,fd,const void *,buf,size_t,count); -#define WRITE(fd, buf, count) __kernel_write(fd, buf, count) - -/* not using __NR_ */ -#define __NR___kernel_gettimeofday __NR_gettimeofday -static __always_inline _syscall2(int,__kernel_gettimeofday,struct timeval *,tv,struct timezone *,tz); -#define GETTIMEOFDAY(tv, tz) __kernel_gettimeofday(tv, tz) - -#define __NR___kernel_getpid __NR_getpid -static __always_inline _syscall0(pid_t,__kernel_getpid); -#define GETPID() __kernel_getpid() - -//#ifdef __NR_rt_sigaction -//#define __NR___kernel_sigaction __NR_rt_sigaction -//static __always_inline _syscall4(...); -//#else -#define __NR___kernel_sigaction __NR_sigaction -static __always_inline _syscall3(int,__kernel_sigaction,int,signum,const struct sigaction *,act,struct sigaction *,oldact); -//#endif -#define SIGACTION(signum, act, oldact) __kernel_sigaction(signum, act, oldact) - -//#ifdef __NR_rt_sigprocmask -//#define __NR___kernel_sigprocmask __NR_rt_sigprocmask -//static __always_inline _syscall4(...); -//#else -#define __NR___kernel_sigprocmask __NR_sigprocmask -static __always_inline _syscall3(int,__kernel_sigprocmask,int,how,const sigset_t *,set,sigset_t *,oldset); -//#endif -#define SIGPROCMASK(how, set, oldset) __kernel_sigprocmask(how, set, oldset) - -#define __NR___kernel_kill __NR_kill -static __always_inline _syscall2(int,__kernel_kill,__kernel_pid_t,pid,int,sig); -#define KILL(pid, sig) __kernel_kill(pid, sig) - -#define __NR___kernel_exit __NR_exit -static __always_inline _syscall1(void,__kernel_exit,int,status); -#define EXIT(status) __kernel_exit(status) - -#endif /* _SSP_INTERNAL_H */ diff --git a/include/string.h b/include/string.h index ea59d94ed..4623a672b 100644 --- a/include/string.h +++ b/include/string.h @@ -236,9 +236,11 @@ extern void *memmem (__const void *__haystack, size_t __haystacklen, /* Copy N bytes of SRC to DEST, return pointer to bytes after the last written byte. */ +#if 0 /* uClibc: disabled */ extern void *__mempcpy (void *__restrict __dest, __const void *__restrict __src, size_t __n) __THROW __nonnull ((1, 2)); +#endif extern void *mempcpy (void *__restrict __dest, __const void *__restrict __src, size_t __n) __THROW __nonnull ((1, 2)); @@ -302,7 +304,9 @@ extern char * __REDIRECT (strerror_r, /* We define this function always since `bzero' is sometimes needed when the namespace rules does not allow this. */ +#if 0 /* uClibc: disabled */ extern void __bzero (void *__s, size_t __n) __THROW __nonnull ((1)); +#endif #ifdef __USE_BSD /* Copy N bytes of SRC to DEST (like memmove, but args reversed). */ |