diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/busybox.h | 32 | ||||
-rw-r--r-- | include/grp.h | 28 | ||||
-rw-r--r-- | include/pwd.h | 29 |
3 files changed, 19 insertions, 70 deletions
diff --git a/include/busybox.h b/include/busybox.h index be6c6f305..5f9425a5b 100644 --- a/include/busybox.h +++ b/include/busybox.h @@ -26,19 +26,10 @@ #include "Config.h" -#include <stdlib.h> +#include <stdio.h> #include <stdarg.h> -#include <string.h> -#include <unistd.h> -#include <errno.h> #include <sys/stat.h> -#include <sys/param.h> #include <sys/types.h> -#include <mntent.h> -#include <regex.h> -/* for the _syscall() macros */ -#include <sys/syscall.h> -#include <linux/unistd.h> #ifdef DMALLOC #include "dmalloc.h" @@ -69,26 +60,6 @@ static inline int is_octal(ch) { return ((ch >= '0') && (ch <= '7')); } #endif -/* I don't like nested includes, but the string and io functions are used - * too often - */ -#include <stdio.h> -#if !defined(NO_STRING_H) || defined(STDC_HEADERS) -# include <string.h> -# if !defined(STDC_HEADERS) && !defined(NO_MEMORY_H) && !defined(__GNUC__) -# include <memory.h> -# endif -# define memzero(s, n) memset ((void *)(s), 0, (n)) -#else -# include <strings.h> -# define strchr index -# define strrchr rindex -# define memcpy(d, s, n) bcopy((s), (d), (n)) -# define memcmp(s1, s2, n) bcmp((s1), (s2), (n)) -# define memzero(s, n) bzero((s), (n)) -#endif - - enum Location { _BB_DIR_ROOT = 0, _BB_DIR_BIN, @@ -179,7 +150,6 @@ extern void print_file(FILE *file); extern int print_file_by_name(char *filename); extern char process_escape_sequence(char **ptr); extern char *get_last_path_component(char *path); -extern void xregcomp(regex_t *preg, const char *regex, int cflags); extern FILE *wfopen(const char *path, const char *mode); extern FILE *xfopen(const char *path, const char *mode); diff --git a/include/grp.h b/include/grp.h index f27c466fd..87d4115ce 100644 --- a/include/grp.h +++ b/include/grp.h @@ -5,16 +5,6 @@ #include <grp.h> #else -#define bb_setgrent setgrent -#define bb_endgrent endgrent -#define bb_getgrent getgrent -#define bb_getgrgid getgrgid -#define bb_getgrnam getgrnam -#define bb_fgetgrent fgetgrent -#define bb_setgroups setgroups -#define bb_initgroups initgroups -#define __bb_getgrent __getgrent - #include <sys/types.h> #include <features.h> #include <stdio.h> @@ -28,19 +18,19 @@ struct group char **gr_mem; /* Member list. */ }; -extern void bb_setgrent __P ((void)); -extern void bb_endgrent __P ((void)); -extern struct group * bb_getgrent __P ((void)); +extern void setgrent __P ((void)); +extern void endgrent __P ((void)); +extern struct group * getgrent __P ((void)); -extern struct group * bb_getgrgid __P ((__const gid_t gid)); -extern struct group * bb_getgrnam __P ((__const char * name)); +extern struct group * getgrgid __P ((__const gid_t gid)); +extern struct group * getgrnam __P ((__const char * name)); -extern struct group * bb_fgetgrent __P ((FILE * file)); +extern struct group * fgetgrent __P ((FILE * file)); -extern int bb_setgroups __P ((size_t n, __const gid_t * groups)); -extern int bb_initgroups __P ((__const char * user, gid_t gid)); +extern int setgroups __P ((size_t n, __const gid_t * groups)); +extern int initgroups __P ((__const char * user, gid_t gid)); -extern struct group * __bb_getgrent __P ((int grp_fd)); +extern struct group * __getgrent __P ((int grp_fd)); #endif /* USE_SYSTEM_PWD_GRP */ #endif /* __BB_GRP_H */ diff --git a/include/pwd.h b/include/pwd.h index 82743f5ad..e603a96e3 100644 --- a/include/pwd.h +++ b/include/pwd.h @@ -5,17 +5,6 @@ #include <pwd.h> #else -#define bb_setpwent setpwent -#define bb_endpwent endpwent -#define bb_getpwent getpwent -#define bb_putpwent putpwent -#define bb_getpw getpw -#define bb_fgetpwent fgetpwent -#define bb_getpwuid getpwuid -#define bb_getpwnam getpwnam -#define __bb_getpwent __bb_getpwent - - #include <sys/types.h> #include <features.h> #include <stdio.h> @@ -32,19 +21,19 @@ struct passwd char *pw_shell; /* Shell program. */ }; -extern void bb_setpwent __P ((void)); -extern void bb_endpwent __P ((void)); -extern struct passwd * bb_getpwent __P ((void)); +extern void setpwent __P ((void)); +extern void endpwent __P ((void)); +extern struct passwd * getpwent __P ((void)); -extern int bb_putpwent __P ((__const struct passwd * __p, FILE * __f)); -extern int bb_getpw __P ((uid_t uid, char *buf)); +extern int putpwent __P ((__const struct passwd * __p, FILE * __f)); +extern int getpw __P ((uid_t uid, char *buf)); -extern struct passwd * bb_fgetpwent __P ((FILE * file)); +extern struct passwd * fgetpwent __P ((FILE * file)); -extern struct passwd * bb_getpwuid __P ((__const uid_t)); -extern struct passwd * bb_getpwnam __P ((__const char *)); +extern struct passwd * getpwuid __P ((__const uid_t)); +extern struct passwd * getpwnam __P ((__const char *)); -extern struct passwd * __bb_getpwent __P ((__const int passwd_fd)); +extern struct passwd * __getpwent __P ((__const int passwd_fd)); #endif /* USE_SYSTEM_PWD_GRP */ #endif /* __BB_PWD_H */ |