From add076e220fdffdeb6de5ae9a9efb6c7e3e0303e Mon Sep 17 00:00:00 2001 From: Mystery Man Date: Thu, 22 Aug 2002 15:26:01 +0000 Subject: This commit was manufactured by cvs2svn to create tag 'V1_1_9_16mdk'. --- mdk-stage1/dietlibc/include/alloca.h | 0 mdk-stage1/dietlibc/include/arpa/inet.h | 19 -- mdk-stage1/dietlibc/include/arpa/nameser.h | 217 ------------- mdk-stage1/dietlibc/include/assert.h | 27 -- mdk-stage1/dietlibc/include/ctype.h | 28 -- mdk-stage1/dietlibc/include/daemon.h | 6 - mdk-stage1/dietlibc/include/dirent.h | 26 -- mdk-stage1/dietlibc/include/dlfcn.h | 15 - mdk-stage1/dietlibc/include/elf.h | 1 - mdk-stage1/dietlibc/include/endian.h | 43 --- mdk-stage1/dietlibc/include/errno.h | 11 - mdk-stage1/dietlibc/include/fcntl.h | 24 -- mdk-stage1/dietlibc/include/features.h | 3 - mdk-stage1/dietlibc/include/fnmatch.h | 15 - mdk-stage1/dietlibc/include/ftw.h | 51 --- mdk-stage1/dietlibc/include/getopt.h | 32 -- mdk-stage1/dietlibc/include/glob.h | 55 ---- mdk-stage1/dietlibc/include/grp.h | 25 -- mdk-stage1/dietlibc/include/inttypes.h | 0 mdk-stage1/dietlibc/include/limits.h | 48 --- mdk-stage1/dietlibc/include/locale.h | 6 - mdk-stage1/dietlibc/include/malloc.h | 1 - mdk-stage1/dietlibc/include/math.h | 61 ---- mdk-stage1/dietlibc/include/memory.h | 6 - mdk-stage1/dietlibc/include/mntent.h | 72 ----- mdk-stage1/dietlibc/include/net/if.h | 11 - mdk-stage1/dietlibc/include/net/if_arp.h | 6 - mdk-stage1/dietlibc/include/net/route.h | 6 - mdk-stage1/dietlibc/include/netdb.h | 90 ------ mdk-stage1/dietlibc/include/netinet/in.h | 9 - mdk-stage1/dietlibc/include/netinet/in_systm.h | 0 mdk-stage1/dietlibc/include/netinet/ip.h | 6 - mdk-stage1/dietlibc/include/paths.h | 16 - mdk-stage1/dietlibc/include/pthread.h | 227 ------------- mdk-stage1/dietlibc/include/pwd.h | 24 -- mdk-stage1/dietlibc/include/regex.h | 67 ---- mdk-stage1/dietlibc/include/resolv.h | 1 - mdk-stage1/dietlibc/include/rpc/auth.h | 213 ------------- mdk-stage1/dietlibc/include/rpc/auth_des.h | 112 ------- mdk-stage1/dietlibc/include/rpc/auth_unix.h | 90 ------ mdk-stage1/dietlibc/include/rpc/clnt.h | 421 ------------------------- mdk-stage1/dietlibc/include/rpc/des_crypt.h | 97 ------ mdk-stage1/dietlibc/include/rpc/key_prot.h | 346 -------------------- mdk-stage1/dietlibc/include/rpc/netdb.h | 74 ----- mdk-stage1/dietlibc/include/rpc/pmap_clnt.h | 98 ------ mdk-stage1/dietlibc/include/rpc/pmap_prot.h | 108 ------- mdk-stage1/dietlibc/include/rpc/pmap_rmt.h | 68 ---- mdk-stage1/dietlibc/include/rpc/rpc.h | 72 ----- mdk-stage1/dietlibc/include/rpc/rpc_des.h | 72 ----- mdk-stage1/dietlibc/include/rpc/rpc_msg.h | 202 ------------ mdk-stage1/dietlibc/include/rpc/svc.h | 316 ------------------- mdk-stage1/dietlibc/include/rpc/svc_auth.h | 54 ---- mdk-stage1/dietlibc/include/rpc/types.h | 78 ----- mdk-stage1/dietlibc/include/rpc/xdr.h | 379 ---------------------- mdk-stage1/dietlibc/include/sched.h | 74 ----- mdk-stage1/dietlibc/include/scsi/scsi.h | 224 ------------- mdk-stage1/dietlibc/include/scsi/scsi_ioctl.h | 34 -- mdk-stage1/dietlibc/include/scsi/sg.h | 274 ---------------- mdk-stage1/dietlibc/include/setjmp.h | 123 -------- mdk-stage1/dietlibc/include/shadow.h | 24 -- mdk-stage1/dietlibc/include/signal.h | 35 -- mdk-stage1/dietlibc/include/stdint.h | 6 - mdk-stage1/dietlibc/include/stdio.h | 97 ------ mdk-stage1/dietlibc/include/stdlib.h | 67 ---- mdk-stage1/dietlibc/include/string.h | 57 ---- mdk-stage1/dietlibc/include/strings.h | 2 - mdk-stage1/dietlibc/include/sys/cdefs.h | 36 --- mdk-stage1/dietlibc/include/sys/file.h | 19 -- mdk-stage1/dietlibc/include/sys/io.h | 41 --- mdk-stage1/dietlibc/include/sys/ioctl.h | 10 - mdk-stage1/dietlibc/include/sys/ipc.h | 8 - mdk-stage1/dietlibc/include/sys/kd.h | 6 - mdk-stage1/dietlibc/include/sys/mman.h | 33 -- mdk-stage1/dietlibc/include/sys/mount.h | 19 -- mdk-stage1/dietlibc/include/sys/msg.h | 13 - mdk-stage1/dietlibc/include/sys/mtio.h | 6 - mdk-stage1/dietlibc/include/sys/param.h | 8 - mdk-stage1/dietlibc/include/sys/poll.h | 11 - mdk-stage1/dietlibc/include/sys/ptrace.h | 10 - mdk-stage1/dietlibc/include/sys/reboot.h | 9 - mdk-stage1/dietlibc/include/sys/resource.h | 16 - mdk-stage1/dietlibc/include/sys/select.h | 0 mdk-stage1/dietlibc/include/sys/sem.h | 11 - mdk-stage1/dietlibc/include/sys/sendfile.h | 9 - mdk-stage1/dietlibc/include/sys/shm.h | 17 - mdk-stage1/dietlibc/include/sys/signal.h | 1 - mdk-stage1/dietlibc/include/sys/socket.h | 46 --- mdk-stage1/dietlibc/include/sys/stat.h | 52 --- mdk-stage1/dietlibc/include/sys/syscall.h | 6 - mdk-stage1/dietlibc/include/sys/sysinfo.h | 9 - mdk-stage1/dietlibc/include/sys/syslog.h | 102 ------ mdk-stage1/dietlibc/include/sys/time.h | 46 --- mdk-stage1/dietlibc/include/sys/times.h | 8 - mdk-stage1/dietlibc/include/sys/types.h | 33 -- mdk-stage1/dietlibc/include/sys/uio.h | 9 - mdk-stage1/dietlibc/include/sys/un.h | 8 - mdk-stage1/dietlibc/include/sys/utsname.h | 35 -- mdk-stage1/dietlibc/include/sys/vfs.h | 11 - mdk-stage1/dietlibc/include/sys/wait.h | 37 --- mdk-stage1/dietlibc/include/syslog.h | 1 - mdk-stage1/dietlibc/include/termios.h | 22 -- mdk-stage1/dietlibc/include/time.h | 24 -- mdk-stage1/dietlibc/include/unistd.h | 168 ---------- mdk-stage1/dietlibc/include/utime.h | 16 - mdk-stage1/dietlibc/include/utmp.h | 73 ----- 105 files changed, 6061 deletions(-) delete mode 100644 mdk-stage1/dietlibc/include/alloca.h delete mode 100644 mdk-stage1/dietlibc/include/arpa/inet.h delete mode 100644 mdk-stage1/dietlibc/include/arpa/nameser.h delete mode 100644 mdk-stage1/dietlibc/include/assert.h delete mode 100644 mdk-stage1/dietlibc/include/ctype.h delete mode 100644 mdk-stage1/dietlibc/include/daemon.h delete mode 100644 mdk-stage1/dietlibc/include/dirent.h delete mode 100644 mdk-stage1/dietlibc/include/dlfcn.h delete mode 100644 mdk-stage1/dietlibc/include/elf.h delete mode 100644 mdk-stage1/dietlibc/include/endian.h delete mode 100644 mdk-stage1/dietlibc/include/errno.h delete mode 100644 mdk-stage1/dietlibc/include/fcntl.h delete mode 100644 mdk-stage1/dietlibc/include/features.h delete mode 100644 mdk-stage1/dietlibc/include/fnmatch.h delete mode 100644 mdk-stage1/dietlibc/include/ftw.h delete mode 100644 mdk-stage1/dietlibc/include/getopt.h delete mode 100644 mdk-stage1/dietlibc/include/glob.h delete mode 100644 mdk-stage1/dietlibc/include/grp.h delete mode 100644 mdk-stage1/dietlibc/include/inttypes.h delete mode 100644 mdk-stage1/dietlibc/include/limits.h delete mode 100644 mdk-stage1/dietlibc/include/locale.h delete mode 100644 mdk-stage1/dietlibc/include/malloc.h delete mode 100644 mdk-stage1/dietlibc/include/math.h delete mode 100644 mdk-stage1/dietlibc/include/memory.h delete mode 100644 mdk-stage1/dietlibc/include/mntent.h delete mode 100644 mdk-stage1/dietlibc/include/net/if.h delete mode 100644 mdk-stage1/dietlibc/include/net/if_arp.h delete mode 100644 mdk-stage1/dietlibc/include/net/route.h delete mode 100644 mdk-stage1/dietlibc/include/netdb.h delete mode 100644 mdk-stage1/dietlibc/include/netinet/in.h delete mode 100644 mdk-stage1/dietlibc/include/netinet/in_systm.h delete mode 100644 mdk-stage1/dietlibc/include/netinet/ip.h delete mode 100644 mdk-stage1/dietlibc/include/paths.h delete mode 100644 mdk-stage1/dietlibc/include/pthread.h delete mode 100644 mdk-stage1/dietlibc/include/pwd.h delete mode 100644 mdk-stage1/dietlibc/include/regex.h delete mode 100644 mdk-stage1/dietlibc/include/resolv.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/auth.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/auth_des.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/auth_unix.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/clnt.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/des_crypt.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/key_prot.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/netdb.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/pmap_clnt.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/pmap_prot.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/pmap_rmt.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/rpc.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/rpc_des.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/rpc_msg.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/svc.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/svc_auth.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/types.h delete mode 100644 mdk-stage1/dietlibc/include/rpc/xdr.h delete mode 100644 mdk-stage1/dietlibc/include/sched.h delete mode 100644 mdk-stage1/dietlibc/include/scsi/scsi.h delete mode 100644 mdk-stage1/dietlibc/include/scsi/scsi_ioctl.h delete mode 100644 mdk-stage1/dietlibc/include/scsi/sg.h delete mode 100644 mdk-stage1/dietlibc/include/setjmp.h delete mode 100644 mdk-stage1/dietlibc/include/shadow.h delete mode 100644 mdk-stage1/dietlibc/include/signal.h delete mode 100644 mdk-stage1/dietlibc/include/stdint.h delete mode 100644 mdk-stage1/dietlibc/include/stdio.h delete mode 100644 mdk-stage1/dietlibc/include/stdlib.h delete mode 100644 mdk-stage1/dietlibc/include/string.h delete mode 100644 mdk-stage1/dietlibc/include/strings.h delete mode 100644 mdk-stage1/dietlibc/include/sys/cdefs.h delete mode 100644 mdk-stage1/dietlibc/include/sys/file.h delete mode 100644 mdk-stage1/dietlibc/include/sys/io.h delete mode 100644 mdk-stage1/dietlibc/include/sys/ioctl.h delete mode 100644 mdk-stage1/dietlibc/include/sys/ipc.h delete mode 100644 mdk-stage1/dietlibc/include/sys/kd.h delete mode 100644 mdk-stage1/dietlibc/include/sys/mman.h delete mode 100644 mdk-stage1/dietlibc/include/sys/mount.h delete mode 100644 mdk-stage1/dietlibc/include/sys/msg.h delete mode 100644 mdk-stage1/dietlibc/include/sys/mtio.h delete mode 100644 mdk-stage1/dietlibc/include/sys/param.h delete mode 100644 mdk-stage1/dietlibc/include/sys/poll.h delete mode 100644 mdk-stage1/dietlibc/include/sys/ptrace.h delete mode 100644 mdk-stage1/dietlibc/include/sys/reboot.h delete mode 100644 mdk-stage1/dietlibc/include/sys/resource.h delete mode 100644 mdk-stage1/dietlibc/include/sys/select.h delete mode 100644 mdk-stage1/dietlibc/include/sys/sem.h delete mode 100644 mdk-stage1/dietlibc/include/sys/sendfile.h delete mode 100644 mdk-stage1/dietlibc/include/sys/shm.h delete mode 100644 mdk-stage1/dietlibc/include/sys/signal.h delete mode 100644 mdk-stage1/dietlibc/include/sys/socket.h delete mode 100644 mdk-stage1/dietlibc/include/sys/stat.h delete mode 100644 mdk-stage1/dietlibc/include/sys/syscall.h delete mode 100644 mdk-stage1/dietlibc/include/sys/sysinfo.h delete mode 100644 mdk-stage1/dietlibc/include/sys/syslog.h delete mode 100644 mdk-stage1/dietlibc/include/sys/time.h delete mode 100644 mdk-stage1/dietlibc/include/sys/times.h delete mode 100644 mdk-stage1/dietlibc/include/sys/types.h delete mode 100644 mdk-stage1/dietlibc/include/sys/uio.h delete mode 100644 mdk-stage1/dietlibc/include/sys/un.h delete mode 100644 mdk-stage1/dietlibc/include/sys/utsname.h delete mode 100644 mdk-stage1/dietlibc/include/sys/vfs.h delete mode 100644 mdk-stage1/dietlibc/include/sys/wait.h delete mode 100644 mdk-stage1/dietlibc/include/syslog.h delete mode 100644 mdk-stage1/dietlibc/include/termios.h delete mode 100644 mdk-stage1/dietlibc/include/time.h delete mode 100644 mdk-stage1/dietlibc/include/unistd.h delete mode 100644 mdk-stage1/dietlibc/include/utime.h delete mode 100644 mdk-stage1/dietlibc/include/utmp.h (limited to 'mdk-stage1/dietlibc/include') diff --git a/mdk-stage1/dietlibc/include/alloca.h b/mdk-stage1/dietlibc/include/alloca.h deleted file mode 100644 index e69de29bb..000000000 diff --git a/mdk-stage1/dietlibc/include/arpa/inet.h b/mdk-stage1/dietlibc/include/arpa/inet.h deleted file mode 100644 index 6d5a6dc35..000000000 --- a/mdk-stage1/dietlibc/include/arpa/inet.h +++ /dev/null @@ -1,19 +0,0 @@ -#ifndef _ARPA_INET_H -#define _ARPA_INET_H - -#include -#include -#include - -int inet_aton(const char *cp, struct in_addr *inp) __THROW; -unsigned long int inet_addr(const char *cp) __THROW; -unsigned long int inet_network(const char *cp) __THROW; -char *inet_ntoa(struct in_addr in) __THROW; -struct in_addr inet_makeaddr(int net, int host) __THROW; -unsigned long int inet_lnaof(struct in_addr in) __THROW; -unsigned long int inet_netof(struct in_addr in) __THROW; - -int inet_pton (int AF, const char* CP, void* BUF) __THROW; -const char* inet_ntop (int AF, const void* CP, char* BUF, size_t LEN) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/arpa/nameser.h b/mdk-stage1/dietlibc/include/arpa/nameser.h deleted file mode 100644 index 1ee048d66..000000000 --- a/mdk-stage1/dietlibc/include/arpa/nameser.h +++ /dev/null @@ -1,217 +0,0 @@ -#ifndef _ARPA_NAMESER_H -#define _ARPA_NAMESER_H - -#include - -#define NS_PACKETSZ 512 /* maximum packet size */ -#define NS_MAXDNAME 1025 /* maximum domain name */ -#define NS_MAXCDNAME 255 /* maximum compressed domain name */ -#define NS_MAXLABEL 63 /* maximum length of domain label */ -#define NS_HFIXEDSZ 12 /* #/bytes of fixed data in header */ -#define NS_QFIXEDSZ 4 /* #/bytes of fixed data in query */ -#define NS_RRFIXEDSZ 10 /* #/bytes of fixed data in r record */ -#define NS_INT32SZ 4 /* #/bytes of data in a u_int32_t */ -#define NS_INT16SZ 2 /* #/bytes of data in a u_int16_t */ -#define NS_INT8SZ 1 /* #/bytes of data in a u_int8_t */ -#define NS_INADDRSZ 4 /* IPv4 T_A */ -#define NS_IN6ADDRSZ 16 /* IPv6 T_AAAA */ -#define NS_CMPRSFLGS 0xc0 /* Flag bits indicating name compression. */ -#define NS_DEFAULTPORT 53 /* For both TCP and UDP. */ - -/* - * Currently defined type values for resources and queries. - */ -typedef enum __ns_type { - ns_t_invalid = 0, /* Cookie. */ - ns_t_a = 1, /* Host address. */ - ns_t_ns = 2, /* Authoritative server. */ - ns_t_md = 3, /* Mail destination. */ - ns_t_mf = 4, /* Mail forwarder. */ - ns_t_cname = 5, /* Canonical name. */ - ns_t_soa = 6, /* Start of authority zone. */ - ns_t_mb = 7, /* Mailbox domain name. */ - ns_t_mg = 8, /* Mail group member. */ - ns_t_mr = 9, /* Mail rename name. */ - ns_t_null = 10, /* Null resource record. */ - ns_t_wks = 11, /* Well known service. */ - ns_t_ptr = 12, /* Domain name pointer. */ - ns_t_hinfo = 13, /* Host information. */ - ns_t_minfo = 14, /* Mailbox information. */ - ns_t_mx = 15, /* Mail routing information. */ - ns_t_txt = 16, /* Text strings. */ - ns_t_rp = 17, /* Responsible person. */ - ns_t_afsdb = 18, /* AFS cell database. */ - ns_t_x25 = 19, /* X_25 calling address. */ - ns_t_isdn = 20, /* ISDN calling address. */ - ns_t_rt = 21, /* Router. */ - ns_t_nsap = 22, /* NSAP address. */ - ns_t_nsap_ptr = 23, /* Reverse NSAP lookup (deprecated). */ - ns_t_sig = 24, /* Security signature. */ - ns_t_key = 25, /* Security key. */ - ns_t_px = 26, /* X.400 mail mapping. */ - ns_t_gpos = 27, /* Geographical position (withdrawn). */ - ns_t_aaaa = 28, /* Ip6 Address. */ - ns_t_loc = 29, /* Location Information. */ - ns_t_nxt = 30, /* Next domain (security). */ - ns_t_eid = 31, /* Endpoint identifier. */ - ns_t_nimloc = 32, /* Nimrod Locator. */ - ns_t_srv = 33, /* Server Selection. */ - ns_t_atma = 34, /* ATM Address */ - ns_t_naptr = 35, /* Naming Authority PoinTeR */ - ns_t_kx = 36, /* Key Exchange */ - ns_t_cert = 37, /* Certification record */ - ns_t_a6 = 38, /* IPv6 address (deprecates AAAA) */ - ns_t_dname = 39, /* Non-terminal DNAME (for IPv6) */ - ns_t_sink = 40, /* Kitchen sink (experimentatl) */ - ns_t_opt = 41, /* EDNS0 option (meta-RR) */ - ns_t_tsig = 250, /* Transaction signature. */ - ns_t_ixfr = 251, /* Incremental zone transfer. */ - ns_t_axfr = 252, /* Transfer zone of authority. */ - ns_t_mailb = 253, /* Transfer mailbox records. */ - ns_t_maila = 254, /* Transfer mail agent records. */ - ns_t_any = 255, /* Wildcard match. */ - ns_t_zxfr = 256, /* BIND-specific, nonstandard. */ - ns_t_max = 65536 -} ns_type; - -/* - * Values for class field - */ -typedef enum __ns_class { - ns_c_invalid = 0, /* Cookie. */ - ns_c_in = 1, /* Internet. */ - ns_c_2 = 2, /* unallocated/unsupported. */ - ns_c_chaos = 3, /* MIT Chaos-net. */ - ns_c_hs = 4, /* MIT Hesiod. */ - /* Query class values which do not appear in resource records */ - ns_c_none = 254, /* for prereq. sections in update requests */ - ns_c_any = 255, /* Wildcard match. */ - ns_c_max = 65536 -} ns_class; - -typedef struct { - unsigned id :16; /* query identification number */ -#if BYTE_ORDER == BIG_ENDIAN - /* fields in third byte */ - unsigned qr: 1; /* response flag */ - unsigned opcode: 4; /* purpose of message */ - unsigned aa: 1; /* authoritive answer */ - unsigned tc: 1; /* truncated message */ - unsigned rd: 1; /* recursion desired */ - /* fields in fourth byte */ - unsigned ra: 1; /* recursion available */ - unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */ - unsigned ad: 1; /* authentic data from named */ - unsigned cd: 1; /* checking disabled by resolver */ - unsigned rcode :4; /* response code */ -#endif -#if BYTE_ORDER == LITTLE_ENDIAN || BYTE_ORDER == PDP_ENDIAN - /* fields in third byte */ - unsigned rd :1; /* recursion desired */ - unsigned tc :1; /* truncated message */ - unsigned aa :1; /* authoritive answer */ - unsigned opcode :4; /* purpose of message */ - unsigned qr :1; /* response flag */ - /* fields in fourth byte */ - unsigned rcode :4; /* response code */ - unsigned cd: 1; /* checking disabled by resolver */ - unsigned ad: 1; /* authentic data from named */ - unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */ - unsigned ra :1; /* recursion available */ -#endif - /* remaining bytes */ - unsigned qdcount :16; /* number of question entries */ - unsigned ancount :16; /* number of answer entries */ - unsigned nscount :16; /* number of authority entries */ - unsigned arcount :16; /* number of resource entries */ -} HEADER; - -#define PACKETSZ NS_PACKETSZ -#define MAXDNAME NS_MAXDNAME -#define MAXCDNAME NS_MAXCDNAME -#define MAXLABEL NS_MAXLABEL -#define HFIXEDSZ NS_HFIXEDSZ -#define QFIXEDSZ NS_QFIXEDSZ -#define RRFIXEDSZ NS_RRFIXEDSZ -#define INT32SZ NS_INT32SZ -#define INT16SZ NS_INT16SZ -#define INADDRSZ NS_INADDRSZ -#define IN6ADDRSZ NS_IN6ADDRSZ -#define INDIR_MASK NS_CMPRSFLGS -#define NAMESERVER_PORT NS_DEFAULTPORT - -#define S_ZONE ns_s_zn -#define S_PREREQ ns_s_pr -#define S_UPDATE ns_s_ud -#define S_ADDT ns_s_ar - -#define QUERY ns_o_query -#define IQUERY ns_o_iquery -#define STATUS ns_o_status -#define NS_NOTIFY_OP ns_o_notify -#define NS_UPDATE_OP ns_o_update - -#define NOERROR ns_r_noerror -#define FORMERR ns_r_formerr -#define SERVFAIL ns_r_servfail -#define NXDOMAIN ns_r_nxdomain -#define NOTIMP ns_r_notimpl -#define REFUSED ns_r_refused -#define YXDOMAIN ns_r_yxdomain -#define YXRRSET ns_r_yxrrset -#define NXRRSET ns_r_nxrrset -#define NOTAUTH ns_r_notauth -#define NOTZONE ns_r_notzone - -#define DELETE ns_uop_delete -#define ADD ns_uop_add - -#define T_A ns_t_a -#define T_NS ns_t_ns -#define T_MD ns_t_md -#define T_MF ns_t_mf -#define T_CNAME ns_t_cname -#define T_SOA ns_t_soa -#define T_MB ns_t_mb -#define T_MG ns_t_mg -#define T_MR ns_t_mr -#define T_NULL ns_t_null -#define T_WKS ns_t_wks -#define T_PTR ns_t_ptr -#define T_HINFO ns_t_hinfo -#define T_MINFO ns_t_minfo -#define T_MX ns_t_mx -#define T_TXT ns_t_txt -#define T_RP ns_t_rp -#define T_AFSDB ns_t_afsdb -#define T_X25 ns_t_x25 -#define T_ISDN ns_t_isdn -#define T_RT ns_t_rt -#define T_NSAP ns_t_nsap -#define T_NSAP_PTR ns_t_nsap_ptr -#define T_SIG ns_t_sig -#define T_KEY ns_t_key -#define T_PX ns_t_px -#define T_GPOS ns_t_gpos -#define T_AAAA ns_t_aaaa -#define T_LOC ns_t_loc -#define T_NXT ns_t_nxt -#define T_EID ns_t_eid -#define T_NIMLOC ns_t_nimloc -#define T_SRV ns_t_srv -#define T_ATMA ns_t_atma -#define T_NAPTR ns_t_naptr -#define T_TSIG ns_t_tsig -#define T_IXFR ns_t_ixfr -#define T_AXFR ns_t_axfr -#define T_MAILB ns_t_mailb -#define T_MAILA ns_t_maila -#define T_ANY ns_t_any - -#define C_IN ns_c_in -#define C_CHAOS ns_c_chaos -#define C_HS ns_c_hs -#define C_NONE ns_c_none -#define C_ANY ns_c_any - -#endif diff --git a/mdk-stage1/dietlibc/include/assert.h b/mdk-stage1/dietlibc/include/assert.h deleted file mode 100644 index bb573d0f2..000000000 --- a/mdk-stage1/dietlibc/include/assert.h +++ /dev/null @@ -1,27 +0,0 @@ -#ifndef _ASSERT_H -#define _ASSERT_H - -#include - -/* This prints an "Assertion failed" message and aborts. */ -extern void __assert_fail (__const char *__assertion, __const char *__file, - unsigned int __line, __const char *__function) - __THROW __attribute__ ((__noreturn__)); - -#ifdef __PRETTY_FUNCTION__ -#define __ASSERT_FUNCTION __PRETTY_FUNCTION__ -#else -#define __ASSERT_FUNCTION __func__ -#endif - -#undef assert -#ifdef NDEBUG -#define assert(expr) -#else -# define assert(expr) \ - ((void) ((expr) ? 0 : \ - (__assert_fail (#expr, \ - __FILE__, __LINE__, __ASSERT_FUNCTION), 0))) -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/ctype.h b/mdk-stage1/dietlibc/include/ctype.h deleted file mode 100644 index 9322e8c7b..000000000 --- a/mdk-stage1/dietlibc/include/ctype.h +++ /dev/null @@ -1,28 +0,0 @@ -#ifndef _CTYPE_H -#define _CTYPE_H - -#include - -extern int isascii (int c) __THROW __attribute__ ((__const__)); -extern int isblank (int c) __THROW __attribute__ ((__const__)); -extern int isalnum (int c) __THROW __attribute__ ((__const__)); -extern int isalpha (int c) __THROW __attribute__ ((__const__)); -extern int isdigit (int c) __THROW __attribute__ ((__const__)); -extern int isspace (int c) __THROW __attribute__ ((__const__)); - -extern int isupper (int c) __THROW __attribute__ ((__const__)); -extern int islower (int c) __THROW __attribute__ ((__const__)); - -extern int tolower(int c) __THROW __attribute__ ((__const__)); -extern int toupper(int c) __THROW __attribute__ ((__const__)); - -extern int isprint(int c) __THROW __attribute__ ((__const__)); -extern int ispunct(int c) __THROW __attribute__ ((__const__)); -extern int iscntrl(int c) __THROW __attribute__ ((__const__)); - -/* fscking GNU extensions! */ -extern int isxdigit(int c) __THROW __attribute__ ((__const__)); - -extern int isgraph(int c) __THROW __attribute__ ((__const__)); - -#endif diff --git a/mdk-stage1/dietlibc/include/daemon.h b/mdk-stage1/dietlibc/include/daemon.h deleted file mode 100644 index 9049f367d..000000000 --- a/mdk-stage1/dietlibc/include/daemon.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _DAEMON_H -#define _DAEMON_H - -extern int daemon (int nochdir,int noclose); - -#endif diff --git a/mdk-stage1/dietlibc/include/dirent.h b/mdk-stage1/dietlibc/include/dirent.h deleted file mode 100644 index b0ad4f5ec..000000000 --- a/mdk-stage1/dietlibc/include/dirent.h +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef _DIRENT_H -#define _DIRENT_H 1 - -#include -#include - -#include - -#define d_fileno d_ino /* Backwards compatibility. */ - -#undef _DIRENT_HAVE_D_NAMLEN -#define _DIRENT_HAVE_D_RECLEN -#define _DIRENT_HAVE_D_OFF -#define _DIRENT_HAVE_D_TYPE - -typedef struct __dirstream DIR; - -DIR *opendir (const char *__name) __THROW; -int closedir (DIR *__dirp) __THROW; -struct dirent *readdir (DIR *__dirp) __THROW; -struct dirent64 *readdir64 (DIR *__dirp) __THROW; -void rewinddir (DIR *__dirp) __THROW; -void seekdir (DIR *__dirp, long int __pos) __THROW; -long int telldir (DIR *__dirp) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/dlfcn.h b/mdk-stage1/dietlibc/include/dlfcn.h deleted file mode 100644 index b96f8f615..000000000 --- a/mdk-stage1/dietlibc/include/dlfcn.h +++ /dev/null @@ -1,15 +0,0 @@ -#ifndef _DLFCN_H -#define _DLFCN_H 1 - -#define RTLD_LAZY 0x00000 -#define RTLD_NOW 0x00001 - -#define RTLD_LOCAL 0x00000 -#define RTLD_GLOBAL 0x10000 - -void *dlopen (const char *filename, int flag); -const char *dlerror(void); -void *dlsym(void *handle, char *symbol); -int dlclose (void *handle); - -#endif diff --git a/mdk-stage1/dietlibc/include/elf.h b/mdk-stage1/dietlibc/include/elf.h deleted file mode 100644 index be09dbee4..000000000 --- a/mdk-stage1/dietlibc/include/elf.h +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/mdk-stage1/dietlibc/include/endian.h b/mdk-stage1/dietlibc/include/endian.h deleted file mode 100644 index 463c24fff..000000000 --- a/mdk-stage1/dietlibc/include/endian.h +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef _ENDIAN_H -#define _ENDIAN_H - -#define __LITTLE_ENDIAN 1234 -#define __BIG_ENDIAN 4321 - -#ifdef __i386__ -#define __BYTE_ORDER __LITTLE_ENDIAN -#define __FLOAT_WORD_ORDER __BYTE_ORDER -#endif - -#ifdef __sparc__ -#define __BYTE_ORDER __BIG_ENDIAN -#define __FLOAT_WORD_ORDER __BYTE_ORDER -#endif - -#ifdef __mips__ -#ifdef __MIPSEB__ -#define __BIG_ENDIAN__ -#endif -#endif - -#ifndef __BYTE_ORDER -#ifdef __BIG_ENDIAN__ -#define __BYTE_ORDER __BIG_ENDIAN -#define __FLOAT_WORD_ORDER __BYTE_ORDER -#else -#define __BYTE_ORDER __LITTLE_ENDIAN -#define __FLOAT_WORD_ORDER __BYTE_ORDER -#endif -#endif - -#define LITTLE_ENDIAN __LITTLE_ENDIAN -#define BIG_ENDIAN __BIG_ENDIAN -#define BYTE_ORDER __BYTE_ORDER - -#if __BYTE_ORDER == __LITTLE_ENDIAN -# define __LONG_LONG_PAIR(HI, LO) LO, HI -#elif __BYTE_ORDER == __BIG_ENDIAN -# define __LONG_LONG_PAIR(HI, LO) HI, LO -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/errno.h b/mdk-stage1/dietlibc/include/errno.h deleted file mode 100644 index d1c68f39c..000000000 --- a/mdk-stage1/dietlibc/include/errno.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef _ERRNO_H -#define _ERRNO_H - -extern int errno; - -#include - -extern int *__errno_location(void); -extern void __set_errno(int error); - -#endif diff --git a/mdk-stage1/dietlibc/include/fcntl.h b/mdk-stage1/dietlibc/include/fcntl.h deleted file mode 100644 index b792502c1..000000000 --- a/mdk-stage1/dietlibc/include/fcntl.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef _FCNTL_H -#define _FCNTL_H - -#include - -#include -#include - -#include - -extern int fcntl (int __fd, int __cmd, ...) __THROW; -extern int open (const char *__file, int __oflag, ...) __THROW; -extern int open64 (const char *__file, int __oflag, ...) __THROW; -extern int creat (const char *__file, mode_t __mode) __THROW; -extern int creat64 (const char *__file, mode_t __mode) __THROW; -extern int lockf (int __fd, int __cmd, off_t __len) __THROW; -extern int lockf64 (int __fd, int __cmd, off64_t __len) __THROW; - -#define F_ULOCK 0 /* Unlock a previously locked region. */ -#define F_LOCK 1 /* Lock a region for exclusive use. */ -#define F_TLOCK 2 /* Test and lock a region for exclusive use. */ -#define F_TEST 3 /* Test a region for other processes locks. */ - -#endif diff --git a/mdk-stage1/dietlibc/include/features.h b/mdk-stage1/dietlibc/include/features.h deleted file mode 100644 index 5b0283f20..000000000 --- a/mdk-stage1/dietlibc/include/features.h +++ /dev/null @@ -1,3 +0,0 @@ -#warning "someone included features.h, apparently someone is including glibc headers!" - -#define __dietlibc__ diff --git a/mdk-stage1/dietlibc/include/fnmatch.h b/mdk-stage1/dietlibc/include/fnmatch.h deleted file mode 100644 index 762b43ff7..000000000 --- a/mdk-stage1/dietlibc/include/fnmatch.h +++ /dev/null @@ -1,15 +0,0 @@ -#ifndef _FNMATCH_H -#define _FNMATCH_H - -#include - -int fnmatch(const char *pattern, const char *string, int flags) __THROW; - -#define FNM_NOESCAPE 1 -#define FNM_PATHNAME 2 -#define FNM_FILE_NAME 2 -#define FNM_PERIOD 4 -#define FNM_LEADING_DIR 8 -#define FNM_CASEFOLD 16 - -#endif diff --git a/mdk-stage1/dietlibc/include/ftw.h b/mdk-stage1/dietlibc/include/ftw.h deleted file mode 100644 index c888f0021..000000000 --- a/mdk-stage1/dietlibc/include/ftw.h +++ /dev/null @@ -1,51 +0,0 @@ -#ifndef _FTW_H -#define _FTW_H - -#include -#include - -struct FTW - { - int base; - int level; - }; - -int ftw (const char *dir, int (*fn)(const char *file, const struct stat *sb, int flag), int depth) __THROW; -int nftw (const char *dir, int (*fn)(const char *file, const struct stat *sb, int flag, struct FTW *s), int depth, int flags) __THROW; - -enum -{ - FTW_F, /* Regular file. */ -#define FTW_F FTW_F - FTW_D, /* Directory. */ -#define FTW_D FTW_D - FTW_DNR, /* Unreadable directory. */ -#define FTW_DNR FTW_DNR - FTW_NS, /* Unstatable file. */ -#define FTW_NS FTW_NS - FTW_SL, /* Symbolic link. */ -# define FTW_SL FTW_SL -/* These flags are only passed from the `nftw' function. */ - FTW_DP, /* Directory, all subdirs have been visited. */ -# define FTW_DP FTW_DP - FTW_SLN /* Symbolic link naming non-existing file. */ -# define FTW_SLN FTW_SLN -}; - -typedef int (*__ftw_func_t) (__const char *__filename, - __const struct stat *__status, int __flag) __THROW; - -typedef int (*__nftw_func_t) (__const char *__filename, - __const struct stat *__status, int __flag, - struct FTW *__info) __THROW; - -#ifndef __NO_STAT64 -typedef int (*__ftw64_func_t) (__const char *__filename, - __const struct stat64 *__status, int __flag) __THROW; - -typedef int (*__nftw64_func_t) (__const char *__filename, - __const struct stat64 *__status, - int __flag, struct FTW *__info) __THROW; -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/getopt.h b/mdk-stage1/dietlibc/include/getopt.h deleted file mode 100644 index ebfc5522d..000000000 --- a/mdk-stage1/dietlibc/include/getopt.h +++ /dev/null @@ -1,32 +0,0 @@ -#ifndef __GETOPT_H__ -#define __GETOPT_H__ - -extern int optind,opterr; -extern char *optarg; -int getopt(int argc, char *argv[], char *options); - -/* the following was taken from GNU getopt, it's not actually supported - * by the diet libc! */ -extern int optopt; - -struct option { - const char* name; - int has_arg; - int* flag; - int val; -}; - -#define no_argument 0 -#define required_argument 1 -#define optional_argument 2 - -extern int getopt_long(int argc, char *const *argv, - const char *shortopts, const struct option *longopts, - int *longind); - -extern int getopt_long_only(int argc, char *const *argv, - const char *shortopts, const struct option *longopts, - int *longind); - - -#endif diff --git a/mdk-stage1/dietlibc/include/glob.h b/mdk-stage1/dietlibc/include/glob.h deleted file mode 100644 index 80febbccf..000000000 --- a/mdk-stage1/dietlibc/include/glob.h +++ /dev/null @@ -1,55 +0,0 @@ -#ifndef _GLOB_H -#define _GLOB_H - - -typedef struct { - size_t gl_pathc; /* Count of paths matched so far */ - char **gl_pathv; /* List of matched pathnames. */ - size_t gl_offs; /* Slots to reserve in `gl_pathv'. */ - int gl_flags; /* Set to FLAGS, maybe | GLOB_MAGCHAR. */ -} glob_t; - - -int glob(const char *pattern, int flags, - int errfunc(const char * epath, int eerrno), - glob_t *pglob) __THROW; - -void globfree(glob_t *pglob) __THROW; - - - -/* Bits set in the FLAGS argument to `glob'. */ -#define GLOB_ERR (1 << 0)/* Return on read errors. */ -#define GLOB_MARK (1 << 1)/* Append a slash to each name. */ -#define GLOB_NOSORT (1 << 2)/* Don't sort the names. */ -#define GLOB_DOOFFS (1 << 3)/* Insert PGLOB->gl_offs NULLs. */ -#define GLOB_NOCHECK (1 << 4)/* If nothing matches, return the pattern. */ -#define GLOB_APPEND (1 << 5)/* Append to results of a previous call. */ -#define GLOB_NOESCAPE (1 << 6)/* Backslashes don't quote metacharacters. */ -#define GLOB_PERIOD (1 << 7)/* Leading `.' can be matched by metachars. */ - -#define GLOB_MAGCHAR (1 << 8)/* Set in gl_flags if any metachars seen. */ -#define GLOB_ALTDIRFUNC (1 << 9)/* Use gl_opendir et al functions. */ -#define GLOB_BRACE (1 << 10)/* Expand "{a,b}" to "a" "b". */ -#define GLOB_NOMAGIC (1 << 11)/* If no magic chars, return the pattern. */ -#define GLOB_TILDE (1 << 12)/* Expand ~user and ~ to home directories. */ -#define GLOB_ONLYDIR (1 << 13)/* Match only directories. */ -#define GLOB_TILDE_CHECK (1 << 14)/* Like GLOB_TILDE but return an error - if the user name is not available. */ -#define __GLOB_FLAGS (GLOB_ERR|GLOB_MARK|GLOB_NOSORT|GLOB_DOOFFS| \ - GLOB_NOESCAPE|GLOB_NOCHECK|GLOB_APPEND| \ - GLOB_PERIOD|GLOB_ALTDIRFUNC|GLOB_BRACE| \ - GLOB_NOMAGIC|GLOB_TILDE|GLOB_ONLYDIR|GLOB_TILDE_CHECK) - - -/* Error returns from `glob'. */ -#define GLOB_NOSPACE 1 /* Ran out of memory. */ -#define GLOB_ABORTED 2 /* Read error. */ -#define GLOB_NOMATCH 3 /* No matches found. */ -#define GLOB_NOSYS 4 /* Not implemented. */ -/* Previous versions of this file defined GLOB_ABEND instead of - GLOB_ABORTED. Provide a compatibility definition here. */ -#define GLOB_ABEND GLOB_ABORTED - - -#endif diff --git a/mdk-stage1/dietlibc/include/grp.h b/mdk-stage1/dietlibc/include/grp.h deleted file mode 100644 index 32bf49afc..000000000 --- a/mdk-stage1/dietlibc/include/grp.h +++ /dev/null @@ -1,25 +0,0 @@ -#ifndef _GRP_H -#define _GRP_H - -#include -#include - -struct group - { - char *gr_name; /* Group name. */ - char *gr_passwd; /* Password. */ - gid_t gr_gid; /* Group ID. */ - char **gr_mem; /* Member list. */ - }; - -extern struct group *getgrgid (gid_t uid) __THROW; -extern struct group *getgrnam (const char *name) __THROW; - -extern struct group *getgrent(void) __THROW; -extern void setgrent(void) __THROW; -extern void endgrent(void) __THROW; - -extern int setgroups(size_t n, const gid_t *groups) __THROW; -extern int initgroups(const char *user, gid_t group) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/inttypes.h b/mdk-stage1/dietlibc/include/inttypes.h deleted file mode 100644 index e69de29bb..000000000 diff --git a/mdk-stage1/dietlibc/include/limits.h b/mdk-stage1/dietlibc/include/limits.h deleted file mode 100644 index a333debfd..000000000 --- a/mdk-stage1/dietlibc/include/limits.h +++ /dev/null @@ -1,48 +0,0 @@ -#ifndef _LIMITS_H -#define _LIMITS_H - -#include - -#define __WORDSIZE 32 - -#ifdef __alpha__ -#undef __WORDSIZE -#define __WORDSIZE 64 -#endif - -#ifndef PATH_MAX -#define PATH_MAX 4096 -#endif - -#define CHAR_BIT 8 - -#define SCHAR_MIN (-128) -#define SCHAR_MAX 0x7f -#define UCHAR_MAX 0xff - -#define SHRT_MIN (-SHRT_MAX-1) -#define SHRT_MAX 0x7fff -#define USHRT_MAX 0xffff - -#define INT_MIN (-INT_MAX-1) -#define INT_MAX 0x7fffffff -#define UINT_MAX 0xffffffff - -#if __WORDSIZE == 64 -#define LONG_MAX 9223372036854775807L -#define ULONG_MAX 18446744073709551615UL -#else -#define LONG_MAX 2147483647L -#define ULONG_MAX 4294967295UL -#endif -#define LONG_MIN (-LONG_MAX - 1L) - -#define LLONG_MAX 9223372036854775807LL -#define LLONG_MIN (-LLONG_MAX - 1LL) - -/* Maximum value an `unsigned long long int' can hold. (Minimum is 0.) */ -#define ULLONG_MAX 18446744073709551615ULL - -#define PASS_MAX 256 - -#endif diff --git a/mdk-stage1/dietlibc/include/locale.h b/mdk-stage1/dietlibc/include/locale.h deleted file mode 100644 index acbeec8c1..000000000 --- a/mdk-stage1/dietlibc/include/locale.h +++ /dev/null @@ -1,6 +0,0 @@ -#warning "there is no locale support for diet libc yet" - -#define setlocale(a,b) 0 -#define bindtextdomain -#define textdomain - diff --git a/mdk-stage1/dietlibc/include/malloc.h b/mdk-stage1/dietlibc/include/malloc.h deleted file mode 100644 index c8b49f26d..000000000 --- a/mdk-stage1/dietlibc/include/malloc.h +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/mdk-stage1/dietlibc/include/math.h b/mdk-stage1/dietlibc/include/math.h deleted file mode 100644 index 2f4f2e33f..000000000 --- a/mdk-stage1/dietlibc/include/math.h +++ /dev/null @@ -1,61 +0,0 @@ -#ifndef _MATH_H -#define _MATH_H - -#include - -#define M_E 2.7182818284590452354 /* e */ -#define M_LOG2E 1.4426950408889634074 /* log_2 e */ -#define M_LOG10E 0.43429448190325182765 /* log_10 e */ -#define M_LN2 0.69314718055994530942 /* log_e 2 */ -#define M_LN10 2.30258509299404568402 /* log_e 10 */ -#define M_PI 3.14159265358979323846 /* pi */ -#define M_PI_2 1.57079632679489661923 /* pi/2 */ -#define M_PI_4 0.78539816339744830962 /* pi/4 */ -#define M_1_PI 0.31830988618379067154 /* 1/pi */ -#define M_2_PI 0.63661977236758134308 /* 2/pi */ -#define M_2_SQRTPI 1.12837916709551257390 /* 2/sqrt(pi) */ -#define M_SQRT2 1.41421356237309504880 /* sqrt(2) */ -#define M_SQRT1_2 0.70710678118654752440 /* 1/sqrt(2) */ - -#define M_El 2.7182818284590452353602874713526625L /* e */ -#define M_LOG2El 1.4426950408889634073599246810018922L /* log_2 e */ -#define M_LOG10El 0.4342944819032518276511289189166051L /* log_10 e */ -#define M_LN2l 0.6931471805599453094172321214581766L /* log_e 2 */ -#define M_LN10l 2.3025850929940456840179914546843642L /* log_e 10 */ -#define M_PIl 3.1415926535897932384626433832795029L /* pi */ -#define M_PI_2l 1.5707963267948966192313216916397514L /* pi/2 */ -#define M_PI_4l 0.7853981633974483096156608458198757L /* pi/4 */ -#define M_1_PIl 0.3183098861837906715377675267450287L /* 1/pi */ -#define M_2_PIl 0.6366197723675813430755350534900574L /* 2/pi */ -#define M_2_SQRTPIl 1.1283791670955125738961589031215452L /* 2/sqrt(pi) */ -#define M_SQRT2l 1.4142135623730950488016887242096981L /* sqrt(2) */ -#define M_SQRT1_2l 0.7071067811865475244008443621048490L /* 1/sqrt(2) */ - -double sin(double d) __THROW __attribute__((__const__)); -double cos(double d) __THROW __attribute__((__const__)); -double tan(double d) __THROW __attribute__((__const__)); - -double sinh(double d) __THROW __attribute__((__const__)); -double cosh(double d) __THROW __attribute__((__const__)); -double tanh(double d) __THROW __attribute__((__const__)); - -double asin(double d) __THROW __attribute__((__const__)); -double acos(double d) __THROW __attribute__((__const__)); -double atan(double d) __THROW __attribute__((__const__)); - -double asinh(double d) __THROW __attribute__((__const__)); -double acosh(double d) __THROW __attribute__((__const__)); -double atanh(double d) __THROW __attribute__((__const__)); - -double exp(double d) __THROW __attribute__((__const__)); -double log(double d) __THROW __attribute__((__const__)); -double log10(double d) __THROW __attribute__((__const__)); - -double pow(double x, double y) __THROW __attribute__((__const__)); - -double sqrt(double x) __THROW __attribute__((__const__)); -double fabs(double x) __THROW __attribute__((__const__)); -double fmod(double x, double y) __THROW __attribute__((__const__)); - - -#endif diff --git a/mdk-stage1/dietlibc/include/memory.h b/mdk-stage1/dietlibc/include/memory.h deleted file mode 100644 index 39adee705..000000000 --- a/mdk-stage1/dietlibc/include/memory.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _MEMORY_H -#define _MEMORY_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/mntent.h b/mdk-stage1/dietlibc/include/mntent.h deleted file mode 100644 index 301403224..000000000 --- a/mdk-stage1/dietlibc/include/mntent.h +++ /dev/null @@ -1,72 +0,0 @@ -#ifndef _MNTENT_H -#define _MNTENT_H - -#include -#include -#include - -#define MNTTAB _PATH_MNTTAB /* Deprecated alias. */ -#define MOUNTED _PATH_MOUNTED /* Deprecated alias. */ - -/* General filesystem types. */ -#define MNTTYPE_IGNORE "ignore" /* Ignore this entry. */ -#define MNTTYPE_NFS "nfs" /* Network file system. */ -#define MNTTYPE_SWAP "swap" /* Swap device. */ - - -/* Generic mount options. */ -#define MNTOPT_DEFAULTS "defaults" /* Use all default options. */ -#define MNTOPT_RO "ro" /* Read only. */ -#define MNTOPT_RW "rw" /* Read/write. */ -#define MNTOPT_SUID "suid" /* Set uid allowed. */ -#define MNTOPT_NOSUID "nosuid" /* No set uid allowed. */ -#define MNTOPT_NOAUTO "noauto" /* Do not auto mount. */ - -__BEGIN_DECLS - -/* Structure describing a mount table entry. */ -struct mntent - { - char *mnt_fsname; /* Device or server for filesystem. */ - char *mnt_dir; /* Directory mounted on. */ - char *mnt_type; /* Type of filesystem: ufs, nfs, etc. */ - char *mnt_opts; /* Comma-separated options for fs. */ - int mnt_freq; /* Dump frequency (in days). */ - int mnt_passno; /* Pass number for `fsck'. */ - }; - - -/* Prepare to begin reading and/or writing mount table entries from the - beginning of FILE. MODE is as for `fopen'. */ -extern FILE *setmntent (const char *file, const char *mode) __THROW; - -/* Read one mount table entry from STREAM. Returns a pointer to storage - reused on the next call, or null for EOF or error (use feof/ferror to - check). */ -extern struct mntent *getmntent (FILE* stream) __THROW; - -#ifdef __USE_MISC -/* Reentrant version of the above function. */ -extern struct mntent *getmntent_r (FILE* stream, - struct mntent* result, - char* buffer, - int bufsize) __THROW; -#endif - -/* Write the mount table entry described by MNT to STREAM. - Return zero on success, nonzero on failure. */ -extern int addmntent (FILE* stream, - const struct mntent* mnt) __THROW; - -/* Close a stream opened with `setmntent'. */ -extern int endmntent (FILE *stream) __THROW; - -/* Search MNT->mnt_opts for an option matching OPT. - Returns the address of the substring, or null if none found. */ -extern char *hasmntopt (const struct mntent *__mnt, - const char *opt) __THROW; - - -__END_DECLS - -#endif /* mntent.h */ diff --git a/mdk-stage1/dietlibc/include/net/if.h b/mdk-stage1/dietlibc/include/net/if.h deleted file mode 100644 index 88f386f46..000000000 --- a/mdk-stage1/dietlibc/include/net/if.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef _NET_IF_H -#define _NET_IF_H - -#include - -#include - -unsigned int if_nametoindex (const char *ifname) __THROW; -char *if_indextoname (unsigned int ifindex, char *ifname) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/net/if_arp.h b/mdk-stage1/dietlibc/include/net/if_arp.h deleted file mode 100644 index fe37a22dc..000000000 --- a/mdk-stage1/dietlibc/include/net/if_arp.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _NET_IF_ARP_H -#define _NET_IF_ARP_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/net/route.h b/mdk-stage1/dietlibc/include/net/route.h deleted file mode 100644 index 5e5db7b1a..000000000 --- a/mdk-stage1/dietlibc/include/net/route.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _NET_IF_ROUTE_H -#define _NET_IF_ROUTE_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/netdb.h b/mdk-stage1/dietlibc/include/netdb.h deleted file mode 100644 index e90ea81ac..000000000 --- a/mdk-stage1/dietlibc/include/netdb.h +++ /dev/null @@ -1,90 +0,0 @@ -#ifndef _NETDB_H -#define _NETDB_H - -#include -#include - -/* Absolute file name for network data base files. */ -#define _PATH_HEQUIV "/etc/hosts.equiv" -#define _PATH_HOSTS "/etc/hosts" -#define _PATH_NETWORKS "/etc/networks" -#define _PATH_NSSWITCH_CONF "/etc/nsswitch.conf" -#define _PATH_PROTOCOLS "/etc/protocols" -#define _PATH_SERVICES "/etc/services" - -/* Description of data base entry for a single service. */ -struct servent -{ - char *s_name; /* Official service name. */ - char **s_aliases; /* Alias list. */ - int s_port; /* Port number. */ - char *s_proto; /* Protocol to use. */ -}; - -extern void endservent (void) __THROW; -extern struct servent *getservent (void) __THROW; -extern struct servent *getservbyname (const char *__name, - const char *__proto) __THROW; -extern struct servent *getservbyport (int __port, const char *__proto) - __THROW; - -struct hostent -{ - char *h_name; /* Official name of host. */ - char **h_aliases; /* Alias list. */ - int h_addrtype; /* Host address type. */ - socklen_t h_length; /* Length of address. */ - char **h_addr_list; /* List of addresses from name server. */ -#define h_addr h_addr_list[0] /* Address, for backward compatibility. */ -}; - -extern void endhostent (void) __THROW; -extern struct hostent *gethostent (void) __THROW; -extern struct hostent *gethostbyaddr (const void *__addr, socklen_t __len, - int __type) __THROW; -extern struct hostent *gethostbyname (const char *__name) __THROW; -extern struct hostent *gethostbyname2 (const char *__name, int __af) __THROW; - -/* this glibc "invention" is so ugly, I'm going to throw up any minute - * now */ -extern int gethostbyname_r(const char* NAME, struct hostent* RESULT_BUF,char* BUF, - size_t BUFLEN, struct hostent** RESULT, - int* H_ERRNOP) __THROW; - -#define HOST_NOT_FOUND 1 -#define TRY_AGAIN 2 -#define NO_RECOVERY 3 -#define NO_ADDRESS 4 - -extern int gethostbyaddr_r(const char* addr, size_t length, int format, - struct hostent* result, char *buf, size_t buflen, - struct hostent **RESULT, int *h_errnop) __THROW; - -struct protoent { - char *p_name; /* official protocol name */ - char **p_aliases; /* alias list */ - int p_proto; /* protocol number */ -}; - -struct protoent *getprotoent(void) __THROW; -struct protoent *getprotobyname(const char *name) __THROW; -struct protoent *getprotobynumber(int proto) __THROW; -void setprotoent(int stayopen) __THROW; -void endprotoent(void) __THROW; - - -/* Description of data base entry for a single network. NOTE: here a - poor assumption is made. The network number is expected to fit - into an unsigned long int variable. */ -struct netent -{ - char *n_name; /* Official name of network. */ - char **n_aliases; /* Alias list. */ - int n_addrtype; /* Net address type. */ - uint32_t n_net; /* Network number. */ -}; - -extern struct netent *getnetbyname (__const char *__name) __THROW; - - -#endif diff --git a/mdk-stage1/dietlibc/include/netinet/in.h b/mdk-stage1/dietlibc/include/netinet/in.h deleted file mode 100644 index 0569c8289..000000000 --- a/mdk-stage1/dietlibc/include/netinet/in.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _NETINET_IN_H -#define _NETINET_IN_H - -#include -#include - -#define IPPORT_RESERVED 1024 - -#endif diff --git a/mdk-stage1/dietlibc/include/netinet/in_systm.h b/mdk-stage1/dietlibc/include/netinet/in_systm.h deleted file mode 100644 index e69de29bb..000000000 diff --git a/mdk-stage1/dietlibc/include/netinet/ip.h b/mdk-stage1/dietlibc/include/netinet/ip.h deleted file mode 100644 index 35bf9cc42..000000000 --- a/mdk-stage1/dietlibc/include/netinet/ip.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _NETINET_IP_H -#define _NETINET_IP_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/paths.h b/mdk-stage1/dietlibc/include/paths.h deleted file mode 100644 index 0e36bb10e..000000000 --- a/mdk-stage1/dietlibc/include/paths.h +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef _PATHS_H -#define _PATHS_H - -#define _PATH_BSHELL "/bin/sh" -#define _PATH_DEFPATH "/bin:/usr/bin:" - -#define _PATH_DEVNULL "/dev/null" - -#define _PATH_CONSOLE "/dev/console" -#define _PATH_MOUNTED "/etc/mtab" - -#define _PATH_PASSWD "/etc/passwd" -#define _PATH_GROUP "/etc/group" -#define _PATH_SHADOW "/etc/shadow" - -#endif diff --git a/mdk-stage1/dietlibc/include/pthread.h b/mdk-stage1/dietlibc/include/pthread.h deleted file mode 100644 index e922ab28b..000000000 --- a/mdk-stage1/dietlibc/include/pthread.h +++ /dev/null @@ -1,227 +0,0 @@ -#ifndef _PTHREAD_H -#define _PTHREAD_H 1 - -#include -#include -#include - -/* arg... kernel haeder... */ -#define ENOTSUP 524 /* Operation is not supported */ - -#define PTHREAD_STACK_SIZE 16384 - -#define PTHREAD_THREADS_MAX 128 - -#define MAX_SPIN_COUNT 50 -#define SPIN_SLEEP_DURATION 2000001 - -#define PTHREAD_KEYS_MAX 7 -#define PTHREAD_DESTRUCTOR_ITERATIONS 10 - -typedef struct _pthread_descr_struct *_pthread_descr; -typedef unsigned long int pthread_t; - -/* Fast locks */ -struct _pthread_fastlock { - int __spinlock; -}; - -/* Mutexes */ -typedef struct { - struct _pthread_fastlock lock; - _pthread_descr owner; - int kind; - unsigned int count; -} pthread_mutex_t; - -enum { - PTHREAD_MUTEX_FAST_NP, - PTHREAD_MUTEX_RECURSIVE_NP, - PTHREAD_MUTEX_ERRORCHECK_NP, -}; - -enum -{ - PTHREAD_PROCESS_PRIVATE, -#define PTHREAD_PROCESS_PRIVATE PTHREAD_PROCESS_PRIVATE - PTHREAD_PROCESS_SHARED -#define PTHREAD_PROCESS_SHARED PTHREAD_PROCESS_SHARED -}; - -#define PTHREAD_MUTEX_INITIALIZER \ -{{0}, 0, PTHREAD_MUTEX_FAST_NP, 0} - -#define PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP \ -{{0}, 0, PTHREAD_MUTEX_RECURSIVE_NP, 0} - -#define PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP \ -{{0}, 0, PTHREAD_MUTEX_ERRORCHECK_NP, 0} - -typedef struct { - int __mutexkind; -} pthread_mutexattr_t; - -int pthread_mutex_init(pthread_mutex_t *mutex, - const pthread_mutexattr_t *mutexattr); -int pthread_mutex_lock(pthread_mutex_t *mutex); -int pthread_mutex_unlock(pthread_mutex_t *mutex); -int pthread_mutex_trylock(pthread_mutex_t *mutex); -int pthread_mutex_destroy(pthread_mutex_t *mutex); - -/* Conditions */ -typedef void* pthread_condattr_t; - -typedef struct { - struct _pthread_fastlock lock; - _pthread_descr wait_chain; -} pthread_cond_t; - -#define PTHREAD_COND_INITIALIZER \ -{{0},0} - -int pthread_cond_init(pthread_cond_t *cond, pthread_condattr_t *cond_attr); -int pthread_cond_destroy(pthread_cond_t *cond); -int pthread_cond_signal(pthread_cond_t *cond); -int pthread_cond_broadcast(pthread_cond_t *cond); -int pthread_cond_timedwait(pthread_cond_t *cond, pthread_mutex_t *mutex, - const struct timespec *abstime); -int pthread_cond_wait(pthread_cond_t *cond, pthread_mutex_t *mutex); - -/* only for completeness (always return NULL) */ -int pthread_condattr_init(pthread_condattr_t *attr); -int pthread_condattr_destroy(pthread_condattr_t *attr); -int pthread_condattr_getpshared(const pthread_condattr_t *attr, int *pshared); -int pthread_condattr_setpshared(pthread_condattr_t *attr, int pshared); - -/* thread specific variables */ -typedef unsigned int pthread_key_t; - -int pthread_key_create(pthread_key_t *key, void (*destructor)(const void*)); -int pthread_key_delete(pthread_key_t key); -int pthread_setspecific(pthread_key_t key, const void *value); -const void *pthread_getspecific(pthread_key_t key); - - -/* Attributes for threads. */ -typedef struct -{ - int __detachstate; - int __schedpolicy; - struct sched_param __schedparam; - int __inheritsched; - int __scope; - void * __stackaddr; - unsigned long __stacksize; -} pthread_attr_t; - -enum -{ - PTHREAD_CREATE_JOINABLE, -#define PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_JOINABLE - PTHREAD_CREATE_DETACHED -#define PTHREAD_CREATE_DETACHED PTHREAD_CREATE_DETACHED -}; - -enum -{ - PTHREAD_EXPLICIT_SCHED, -#define PTHREAD_EXPLICIT_SCHED PTHREAD_EXPLICIT_SCHED - PTHREAD_INHERIT_SCHED -#define PTHREAD_INHERIT_SCHED PTHREAD_INHERIT_SCHED -}; - -enum /* for completeness */ -{ - PTHREAD_SCOPE_SYSTEM, -#define PTHREAD_SCOPE_SYSTEM PTHREAD_SCOPE_SYSTEM - PTHREAD_SCOPE_PROCESS -#define PTHREAD_SCOPE_PROCESS PTHREAD_SCOPE_PROCESS -}; - -int pthread_attr_init(pthread_attr_t *attr); -int pthread_attr_destroy(pthread_attr_t *attr); - -int pthread_attr_setdetachstate(pthread_attr_t *attr, int detachstate); -int pthread_attr_getdetachstate(const pthread_attr_t *attr, int *detachstate); - -int pthread_attr_setschedpolicy(pthread_attr_t *attr, int policy); -int pthread_attr_getschedpolicy(const pthread_attr_t *attr, int *policy); - -int pthread_attr_setschedparam(pthread_attr_t *attr, - const struct sched_param *param); -int pthread_attr_getschedparam(const pthread_attr_t *attr, - struct sched_param *param); - -int pthread_attr_setinheritsched(pthread_attr_t *attr, int inherit); -int pthread_attr_getinheritsched(const pthread_attr_t *attr, int *inherit); - -int pthread_attr_setscope(pthread_attr_t *attr, int scope); -int pthread_attr_getscope(const pthread_attr_t *attr, int *scope); - -int pthread_attr_setstackaddr(pthread_attr_t *attr, void *stack); -int pthread_attr_getstackaddr(pthread_attr_t *attr, void **stack); - -int pthread_attr_setstacksize(pthread_attr_t *attr, size_t stacksize); -int pthread_attr_getstacksize(pthread_attr_t *attr, size_t *stacksize); - -/* ONCE */ -typedef int pthread_once_t; -#define PTHREAD_ONCE_INIT 0 - -int __pthread_once(pthread_once_t* once_control, void (*init_routine)(void)); -int pthread_once(pthread_once_t* once_control, void (*init_routine)(void)); - -/* CANCEL */ - -enum { - PTHREAD_CANCEL_ENABLE, -#define PTHREAD_CANCEL_ENABLE PTHREAD_CANCEL_ENABLE - PTHREAD_CANCEL_DISABLE, -#define PTHREAD_CANCEL_DISABLE PTHREAD_CANCEL_DISABLE -}; - -enum { - PTHREAD_CANCEL_ASYNCHRONOUS, -#define PTHREAD_CANCEL_ASYNCHRONOUS PTHREAD_CANCEL_ASYNCHRONOUS - PTHREAD_CANCEL_DEFERRED, -#define PTHREAD_CANCEL_DEFERRED PTHREAD_CANCEL_DEFERRED -}; - -#define PTHREAD_CANCELED ((void *) -1) - -int pthread_cancel(pthread_t thread); -int pthread_setcancelstate(int state, int *oldstate); - -int pthread_setcanceltype(int type, int *oldtype); - -void pthread_testcancel(void); - -/* CLEANUP */ - -void pthread_cleanup_push(void (*routine)(void*), void *arg); -void pthread_cleanup_pop (int execute); - -void pthread_cleanup_push_defer_np(void (*routine)(void *), void *arg); -void pthread_cleanup_pop_restore_np(int execute); - -/* FORK */ - -pid_t pthread_atfork(void (*prepare)(void), void (*parent)(void), - void (*child)(void)); - -/* THREADS */ -int pthread_create (pthread_t *__thread, - const pthread_attr_t *__attr, - void *(*__start_routine) (void *), - void *__arg); - -void pthread_exit (void *__retval) __attribute__ ((__noreturn__)); - -int pthread_join (pthread_t __th, void **__thread_return); - -int pthread_detach (pthread_t __th); - -pthread_t pthread_self (void); -int pthread_equal (pthread_t __thread1, pthread_t __thread2); - -#endif diff --git a/mdk-stage1/dietlibc/include/pwd.h b/mdk-stage1/dietlibc/include/pwd.h deleted file mode 100644 index e6fb5d0be..000000000 --- a/mdk-stage1/dietlibc/include/pwd.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef _PWD_H -#define _PWD_H - -#include -#include - -struct passwd { - char *pw_name; /* Username. */ - char *pw_passwd; /* Password. */ - uid_t pw_uid; /* User ID. */ - gid_t pw_gid; /* Group ID. */ - char *pw_gecos; /* Real name. */ - char *pw_dir; /* Home directory. */ - char *pw_shell; /* Shell program. */ -}; - -extern struct passwd *getpwuid (uid_t __uid) __THROW; -extern struct passwd *getpwnam (const char *__name) __THROW; - -extern struct passwd *getpwent(void) __THROW; -extern void setpwent(void) __THROW; -extern void endpwent(void) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/regex.h b/mdk-stage1/dietlibc/include/regex.h deleted file mode 100644 index be609d9db..000000000 --- a/mdk-stage1/dietlibc/include/regex.h +++ /dev/null @@ -1,67 +0,0 @@ -#ifndef _REGEX_H -#define _REGEX_H - -#include -#include - -typedef ptrdiff_t regoff_t; - -typedef struct { - regoff_t rm_so; - regoff_t rm_eo; -} regmatch_t; - -#define REG_EXTENDED 1 -#define REG_ICASE 2 -#define REG_NOSUB 4 -#define REG_NEWLINE 8 - -#define REG_NOTBOL 1 -#define REG_NOTEOL 2 - -#define REG_NOMATCH -1 - -#define RE_DUP_MAX 255 - -struct __regex_t; - -typedef int (*matcher)(void*,const char*,int ofs,struct __regex_t *t,int plus,int eflags); - -typedef struct __regex_t { - struct regex { - matcher m; - void* next; - int pieces; - int num; - struct branch *b; - } r; - int brackets,cflags; - regmatch_t *l; -} regex_t; - -int regcomp(regex_t *preg, const char *regex, int cflags) __THROW; -int regexec(const regex_t *preg, const char *string, size_t nmatch, regmatch_t pmatch[], int eflags) __THROW; -size_t regerror(int errcode, const regex_t *preg, char *errbuf, size_t errbuf_size) __THROW; -void regfree(regex_t *preg) __THROW; - -enum __regex_errors { - REG_NOERROR, - REG_BADRPT, /* Invalid use of repetition operators such as using `*' as the first character. */ - REG_BADBR, /* Invalid use of back reference operator. */ - REG_EBRACE, /* Un-matched brace interval operators. */ - REG_EBRACK, /* Un-matched bracket list operators. */ - REG_ERANGE, /* Invalid use of the range operator, eg. the ending point of the - range occurs prior to the starting point. */ - REG_ECTYPE, /* Unknown character class name. */ - REG_ECOLLATE, /* Invalid collating element. */ - REG_EPAREN, /* Un-matched parenthesis group operators. */ - REG_ESUBREG, /* Invalid back reference to a subexpression. */ - REG_EEND, /* Non specific error. This is not defined by POSIX.2. */ - REG_EESCAPE, /* Trailing backslash. */ - REG_BADPAT, /* Invalid use of pattern operators such as group or list. */ - REG_ESIZE, /* Compiled regular expression requires a pattern buffer - larger than 64Kb. This is not defined by POSIX.2. */ - REG_ESPACE, /* regcomp ran out of space */ -}; - -#endif diff --git a/mdk-stage1/dietlibc/include/resolv.h b/mdk-stage1/dietlibc/include/resolv.h deleted file mode 100644 index 4e90799c2..000000000 --- a/mdk-stage1/dietlibc/include/resolv.h +++ /dev/null @@ -1 +0,0 @@ -void res_init(void); diff --git a/mdk-stage1/dietlibc/include/rpc/auth.h b/mdk-stage1/dietlibc/include/rpc/auth.h deleted file mode 100644 index 4aa7d21ce..000000000 --- a/mdk-stage1/dietlibc/include/rpc/auth.h +++ /dev/null @@ -1,213 +0,0 @@ -/* @(#)auth.h 2.3 88/08/07 4.0 RPCSRC; from 1.17 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * auth.h, Authentication interface. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - * - * The data structures are completely opaque to the client. The client - * is required to pass a AUTH * to routines that create rpc - * "sessions". - */ - -#ifndef _RPC_AUTH_H - -#define _RPC_AUTH_H 1 -#include -#include - -__BEGIN_DECLS - -#define MAX_AUTH_BYTES 400 -#define MAXNETNAMELEN 255 /* maximum length of network user's name */ - -/* - * Status returned from authentication check - */ -enum auth_stat { - AUTH_OK=0, - /* - * failed at remote end - */ - AUTH_BADCRED=1, /* bogus credentials (seal broken) */ - AUTH_REJECTEDCRED=2, /* client should begin new session */ - AUTH_BADVERF=3, /* bogus verifier (seal broken) */ - AUTH_REJECTEDVERF=4, /* verifier expired or was replayed */ - AUTH_TOOWEAK=5, /* rejected due to security reasons */ - /* - * failed locally - */ - AUTH_INVALIDRESP=6, /* bogus response verifier */ - AUTH_FAILED=7 /* some unknown reason */ -}; - -union des_block { - struct { - u_int32_t high; - u_int32_t low; - } key; - char c[8]; -}; -typedef union des_block des_block; -extern bool_t xdr_des_block (XDR *__xdrs, des_block *__blkp) __THROW; - -/* - * Authentication info. Opaque to client. - */ -struct opaque_auth { - enum_t oa_flavor; /* flavor of auth */ - caddr_t oa_base; /* address of more auth stuff */ - u_int oa_length; /* not to exceed MAX_AUTH_BYTES */ -}; - -/* - * Auth handle, interface to client side authenticators. - */ -typedef struct AUTH AUTH; -struct AUTH { - struct opaque_auth ah_cred; - struct opaque_auth ah_verf; - union des_block ah_key; - struct auth_ops { - void (*ah_nextverf) (AUTH *); - int (*ah_marshal) (AUTH *, XDR *); /* nextverf & serialize */ - int (*ah_validate) (AUTH *, struct opaque_auth *); - /* validate verifier */ - int (*ah_refresh) (AUTH *); /* refresh credentials */ - void (*ah_destroy) (AUTH *); /* destroy this structure */ - } *ah_ops; - caddr_t ah_private; -}; - - -/* - * Authentication ops. - * The ops and the auth handle provide the interface to the authenticators. - * - * AUTH *auth; - * XDR *xdrs; - * struct opaque_auth verf; - */ -#define AUTH_NEXTVERF(auth) \ - ((*((auth)->ah_ops->ah_nextverf))(auth)) -#define auth_nextverf(auth) \ - ((*((auth)->ah_ops->ah_nextverf))(auth)) - -#define AUTH_MARSHALL(auth, xdrs) \ - ((*((auth)->ah_ops->ah_marshal))(auth, xdrs)) -#define auth_marshall(auth, xdrs) \ - ((*((auth)->ah_ops->ah_marshal))(auth, xdrs)) - -#define AUTH_VALIDATE(auth, verfp) \ - ((*((auth)->ah_ops->ah_validate))((auth), verfp)) -#define auth_validate(auth, verfp) \ - ((*((auth)->ah_ops->ah_validate))((auth), verfp)) - -#define AUTH_REFRESH(auth) \ - ((*((auth)->ah_ops->ah_refresh))(auth)) -#define auth_refresh(auth) \ - ((*((auth)->ah_ops->ah_refresh))(auth)) - -#define AUTH_DESTROY(auth) \ - ((*((auth)->ah_ops->ah_destroy))(auth)) -#define auth_destroy(auth) \ - ((*((auth)->ah_ops->ah_destroy))(auth)) - - -extern struct opaque_auth _null_auth; - - -/* - * These are the various implementations of client side authenticators. - */ - -/* - * Unix style authentication - * AUTH *authunix_create(machname, uid, gid, len, aup_gids) - * char *machname; - * int uid; - * int gid; - * int len; - * int *aup_gids; - */ -extern AUTH *authunix_create (char *__machname,uid_t __uid, gid_t __gid, - int __len, gid_t *__aup_gids) __THROW; -extern AUTH *authunix_create_default (void) __THROW; -extern AUTH *authnone_create (void) __THROW; -extern AUTH *authdes_create (const char *__servername, u_int __window, - struct sockaddr *__syncaddr, des_block *__ckey) - __THROW; -extern AUTH *authdes_pk_create (const char *, netobj *, u_int, - struct sockaddr *, des_block *) __THROW; - - -#define AUTH_NONE 0 /* no authentication */ -#define AUTH_NULL 0 /* backward compatibility */ -#define AUTH_SYS 1 /* unix style (uid, gids) */ -#define AUTH_UNIX AUTH_SYS -#define AUTH_SHORT 2 /* short hand unix style */ -#define AUTH_DES 3 /* des style (encrypted timestamps) */ -#define AUTH_DH AUTH_DES /* Diffie-Hellman (this is DES) */ -#define AUTH_KERB 4 /* kerberos style */ - -/* - * Netname manipulating functions - * - */ -extern int getnetname (char *) __THROW; -extern int host2netname (char *, __const char *, __const char *) __THROW; -extern int user2netname (char *, __const uid_t, __const char *) __THROW; -extern int netname2user (__const char *, uid_t *, gid_t *, int *, gid_t *) - __THROW; -extern int netname2host (__const char *, char *, __const int) __THROW; - -/* - * - * These routines interface to the keyserv daemon - * - */ -extern int key_decryptsession (char *, des_block *) __THROW; -extern int key_decryptsession_pk (char *, netobj *, des_block *) __THROW; -extern int key_encryptsession (char *, des_block *) __THROW; -extern int key_encryptsession_pk (char *, netobj *, des_block *) __THROW; -extern int key_gendes (des_block *) __THROW; -extern int key_setsecret (char *) __THROW; -extern int key_secretkey_is_set (void) __THROW; -extern int key_get_conv (char *, des_block *) __THROW; - -/* - * XDR an opaque authentication struct. - */ -extern bool_t xdr_opaque_auth (XDR *, struct opaque_auth *) __THROW; - -__END_DECLS - -#endif /* rpc/auth.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/auth_des.h b/mdk-stage1/dietlibc/include/rpc/auth_des.h deleted file mode 100644 index 198b299e7..000000000 --- a/mdk-stage1/dietlibc/include/rpc/auth_des.h +++ /dev/null @@ -1,112 +0,0 @@ -/* Copyright (C) 1996, 1997, 1998, 1999 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with the GNU C Library; see the file COPYING.LIB. If not, - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -#ifndef _RPC_AUTH_DES_H -#define _RPC_AUTH_DES_H 1 - -#include -#include - -__BEGIN_DECLS - -/* There are two kinds of "names": fullnames and nicknames */ -enum authdes_namekind - { - ADN_FULLNAME, - ADN_NICKNAME - }; - -/* A fullname contains the network name of the client, - a conversation key and the window */ -struct authdes_fullname - { - char *name; /* network name of client, up to MAXNETNAMELEN */ - des_block key; /* conversation key */ - uint32_t window; /* associated window */ - }; - -/* A credential */ -struct authdes_cred - { - enum authdes_namekind adc_namekind; - struct authdes_fullname adc_fullname; - uint32_t adc_nickname; - }; - -/* A timeval replacement for !32bit platforms */ -struct rpc_timeval - { - uint32_t tv_sec; /* Seconds. */ - uint32_t tv_usec; /* Microseconds. */ - }; - -/* A des authentication verifier */ -struct authdes_verf - { - union - { - struct rpc_timeval adv_ctime; /* clear time */ - des_block adv_xtime; /* crypt time */ - } - adv_time_u; - uint32_t adv_int_u; - }; - -/* des authentication verifier: client variety - - adv_timestamp is the current time. - adv_winverf is the credential window + 1. - Both are encrypted using the conversation key. */ -#define adv_timestamp adv_time_u.adv_ctime -#define adv_xtimestamp adv_time_u.adv_xtime -#define adv_winverf adv_int_u - -/* des authentication verifier: server variety - - adv_timeverf is the client's timestamp + client's window - adv_nickname is the server's nickname for the client. - adv_timeverf is encrypted using the conversation key. */ -#define adv_timeverf adv_time_u.adv_ctime -#define adv_xtimeverf adv_time_u.adv_xtime -#define adv_nickname adv_int_u - -/* Map a des credential into a unix cred. */ -extern int authdes_getucred (__const struct authdes_cred * __adc, - uid_t * __uid, gid_t * __gid, - short *__grouplen, gid_t * __groups) __THROW; - -/* Get the public key for NAME and place it in KEY. NAME can only be - up to MAXNETNAMELEN bytes long and the destination buffer KEY should - have HEXKEYBYTES + 1 bytes long to fit all characters from the key. */ -extern int getpublickey (__const char *__name, char *__key) __THROW; - -/* Get the secret key for NAME and place it in KEY. PASSWD is used to - decrypt the encrypted key stored in the database. NAME can only be - up to MAXNETNAMELEN bytes long and the destination buffer KEY - should have HEXKEYBYTES + 1 bytes long to fit all characters from - the key. */ -extern int getsecretkey (__const char *__name, char *__key, - __const char *__passwd) __THROW; - -extern int rtime (struct sockaddr_in *__addrp, struct rpc_timeval *__timep, - struct rpc_timeval *__timeout) __THROW; - -__END_DECLS - - -#endif /* rpc/auth_des.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/auth_unix.h b/mdk-stage1/dietlibc/include/rpc/auth_unix.h deleted file mode 100644 index 7a1bfa9f0..000000000 --- a/mdk-stage1/dietlibc/include/rpc/auth_unix.h +++ /dev/null @@ -1,90 +0,0 @@ -/* @(#)auth_unix.h 2.2 88/07/29 4.0 RPCSRC; from 1.8 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* @(#)auth_unix.h 1.5 86/07/16 SMI */ - -/* - * auth_unix.h, Protocol for UNIX style authentication parameters for RPC - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -/* - * The system is very weak. The client uses no encryption for it - * credentials and only sends null verifiers. The server sends backs - * null verifiers or optionally a verifier that suggests a new short hand - * for the credentials. - */ - -#ifndef _RPC_AUTH_UNIX_H -#define _RPC_AUTH_UNIX_H 1 - -#include -#include -#include -#include -#include - -__BEGIN_DECLS - -/* The machine name is part of a credential; it may not exceed 255 bytes */ -#define MAX_MACHINE_NAME 255 - -/* gids compose part of a credential; there may not be more than 16 of them */ -#define NGRPS 16 - -/* - * Unix style credentials. - */ -struct authunix_parms - { - u_long aup_time; - char *aup_machname; - uid_t aup_uid; - gid_t aup_gid; - u_int aup_len; - gid_t *aup_gids; - }; - -extern bool_t xdr_authunix_parms (XDR *__xdrs, struct authunix_parms *__p) - __THROW; - -/* - * If a response verifier has flavor AUTH_SHORT, - * then the body of the response verifier encapsulates the following structure; - * again it is serialized in the obvious fashion. - */ -struct short_hand_verf - { - struct opaque_auth new_cred; - }; - -__END_DECLS - -#endif /* rpc/auth_unix.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/clnt.h b/mdk-stage1/dietlibc/include/rpc/clnt.h deleted file mode 100644 index 60b0fafdf..000000000 --- a/mdk-stage1/dietlibc/include/rpc/clnt.h +++ /dev/null @@ -1,421 +0,0 @@ -/* @(#)clnt.h 2.1 88/07/29 4.0 RPCSRC; from 1.31 88/02/08 SMI*/ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * clnt.h - Client side remote procedure call interface. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_CLNT_H -#define _RPC_CLNT_H 1 - -#include -#include -#include -#include -#include - -__BEGIN_DECLS - -/* - * Rpc calls return an enum clnt_stat. This should be looked at more, - * since each implementation is required to live with this (implementation - * independent) list of errors. - */ -enum clnt_stat { - RPC_SUCCESS=0, /* call succeeded */ - /* - * local errors - */ - RPC_CANTENCODEARGS=1, /* can't encode arguments */ - RPC_CANTDECODERES=2, /* can't decode results */ - RPC_CANTSEND=3, /* failure in sending call */ - RPC_CANTRECV=4, /* failure in receiving result */ - RPC_TIMEDOUT=5, /* call timed out */ - /* - * remote errors - */ - RPC_VERSMISMATCH=6, /* rpc versions not compatible */ - RPC_AUTHERROR=7, /* authentication error */ - RPC_PROGUNAVAIL=8, /* program not available */ - RPC_PROGVERSMISMATCH=9, /* program version mismatched */ - RPC_PROCUNAVAIL=10, /* procedure unavailable */ - RPC_CANTDECODEARGS=11, /* decode arguments error */ - RPC_SYSTEMERROR=12, /* generic "other problem" */ - RPC_NOBROADCAST = 21, /* Broadcasting not supported */ - /* - * callrpc & clnt_create errors - */ - RPC_UNKNOWNHOST=13, /* unknown host name */ - RPC_UNKNOWNPROTO=17, /* unknown protocol */ - RPC_UNKNOWNADDR = 19, /* Remote address unknown */ - - /* - * rpcbind errors - */ - RPC_RPCBFAILURE=14, /* portmapper failed in its call */ -#define RPC_PMAPFAILURE RPC_RPCBFAILURE - RPC_PROGNOTREGISTERED=15, /* remote program is not registered */ - RPC_N2AXLATEFAILURE = 22, /* Name to addr translation failed */ - /* - * unspecified error - */ - RPC_FAILED=16, - RPC_INTR=18, - RPC_TLIERROR=20, - RPC_UDERROR=23, - /* - * asynchronous errors - */ - RPC_INPROGRESS = 24, - RPC_STALERACHANDLE = 25 -}; - - -/* - * Error info. - */ -struct rpc_err { - enum clnt_stat re_status; - union { - int RE_errno; /* related system error */ - enum auth_stat RE_why; /* why the auth error occurred */ - struct { - u_long low; /* lowest verion supported */ - u_long high; /* highest verion supported */ - } RE_vers; - struct { /* maybe meaningful if RPC_FAILED */ - long s1; - long s2; - } RE_lb; /* life boot & debugging only */ - } ru; -#define re_errno ru.RE_errno -#define re_why ru.RE_why -#define re_vers ru.RE_vers -#define re_lb ru.RE_lb -}; - - -/* - * Client rpc handle. - * Created by individual implementations, see e.g. rpc_udp.c. - * Client is responsible for initializing auth, see e.g. auth_none.c. - */ -typedef struct CLIENT CLIENT; -struct CLIENT { - AUTH *cl_auth; /* authenticator */ - struct clnt_ops { - enum clnt_stat (*cl_call) (CLIENT *, u_long, xdrproc_t, caddr_t, xdrproc_t, - caddr_t, struct timeval); - /* call remote procedure */ - void (*cl_abort) (void); /* abort a call */ - void (*cl_geterr) (CLIENT *, struct rpc_err *); - /* get specific error code */ - bool_t (*cl_freeres) (CLIENT *, xdrproc_t, caddr_t); - /* frees results */ - void (*cl_destroy) (CLIENT *); /* destroy this structure */ - bool_t (*cl_control) (CLIENT *, int, char *); - /* the ioctl() of rpc */ - } *cl_ops; - caddr_t cl_private; /* private stuff */ -}; - - -/* - * client side rpc interface ops - * - * Parameter types are: - * - */ - -/* - * enum clnt_stat - * CLNT_CALL(rh, proc, xargs, argsp, xres, resp, timeout) - * CLIENT *rh; - * u_long proc; - * xdrproc_t xargs; - * caddr_t argsp; - * xdrproc_t xres; - * caddr_t resp; - * struct timeval timeout; - */ -#define CLNT_CALL(rh, proc, xargs, argsp, xres, resp, secs) \ - ((*(rh)->cl_ops->cl_call)(rh, proc, xargs, argsp, xres, resp, secs)) -#define clnt_call(rh, proc, xargs, argsp, xres, resp, secs) \ - ((*(rh)->cl_ops->cl_call)(rh, proc, xargs, argsp, xres, resp, secs)) - -/* - * void - * CLNT_ABORT(rh); - * CLIENT *rh; - */ -#define CLNT_ABORT(rh) ((*(rh)->cl_ops->cl_abort)(rh)) -#define clnt_abort(rh) ((*(rh)->cl_ops->cl_abort)(rh)) - -/* - * struct rpc_err - * CLNT_GETERR(rh); - * CLIENT *rh; - */ -#define CLNT_GETERR(rh,errp) ((*(rh)->cl_ops->cl_geterr)(rh, errp)) -#define clnt_geterr(rh,errp) ((*(rh)->cl_ops->cl_geterr)(rh, errp)) - - -/* - * bool_t - * CLNT_FREERES(rh, xres, resp); - * CLIENT *rh; - * xdrproc_t xres; - * caddr_t resp; - */ -#define CLNT_FREERES(rh,xres,resp) ((*(rh)->cl_ops->cl_freeres)(rh,xres,resp)) -#define clnt_freeres(rh,xres,resp) ((*(rh)->cl_ops->cl_freeres)(rh,xres,resp)) - -/* - * bool_t - * CLNT_CONTROL(cl, request, info) - * CLIENT *cl; - * u_int request; - * char *info; - */ -#define CLNT_CONTROL(cl,rq,in) ((*(cl)->cl_ops->cl_control)(cl,rq,in)) -#define clnt_control(cl,rq,in) ((*(cl)->cl_ops->cl_control)(cl,rq,in)) - -/* - * control operations that apply to all transports - * - * Note: options marked XXX are no-ops in this implementation of RPC. - * The are present in TI-RPC but can't be implemented here since they - * depend on the presence of STREAMS/TLI, which we don't have. - */ -#define CLSET_TIMEOUT 1 /* set timeout (timeval) */ -#define CLGET_TIMEOUT 2 /* get timeout (timeval) */ -#define CLGET_SERVER_ADDR 3 /* get server's address (sockaddr) */ -#define CLGET_FD 6 /* get connections file descriptor */ -#define CLGET_SVC_ADDR 7 /* get server's address (netbuf) XXX */ -#define CLSET_FD_CLOSE 8 /* close fd while clnt_destroy */ -#define CLSET_FD_NCLOSE 9 /* Do not close fd while clnt_destroy*/ -#define CLGET_XID 10 /* Get xid */ -#define CLSET_XID 11 /* Set xid */ -#define CLGET_VERS 12 /* Get version number */ -#define CLSET_VERS 13 /* Set version number */ -#define CLGET_PROG 14 /* Get program number */ -#define CLSET_PROG 15 /* Set program number */ -#define CLSET_SVC_ADDR 16 /* get server's address (netbuf) XXX */ -#define CLSET_PUSH_TIMOD 17 /* push timod if not already present XXX */ -#define CLSET_POP_TIMOD 18 /* pop timod XXX */ -/* - * Connectionless only control operations - */ -#define CLSET_RETRY_TIMEOUT 4 /* set retry timeout (timeval) */ -#define CLGET_RETRY_TIMEOUT 5 /* get retry timeout (timeval) */ - -/* - * void - * CLNT_DESTROY(rh); - * CLIENT *rh; - */ -#define CLNT_DESTROY(rh) ((*(rh)->cl_ops->cl_destroy)(rh)) -#define clnt_destroy(rh) ((*(rh)->cl_ops->cl_destroy)(rh)) - - -/* - * RPCTEST is a test program which is accessible on every rpc - * transport/port. It is used for testing, performance evaluation, - * and network administration. - */ - -#define RPCTEST_PROGRAM ((u_long)1) -#define RPCTEST_VERSION ((u_long)1) -#define RPCTEST_NULL_PROC ((u_long)2) -#define RPCTEST_NULL_BATCH_PROC ((u_long)3) - -/* - * By convention, procedure 0 takes null arguments and returns them - */ - -#define NULLPROC ((u_long)0) - -/* - * Below are the client handle creation routines for the various - * implementations of client side rpc. They can return NULL if a - * creation failure occurs. - */ - -/* - * Memory based rpc (for speed check and testing) - * CLIENT * - * clntraw_create(prog, vers) - * u_long prog; - * u_long vers; - */ -extern CLIENT *clntraw_create (__const u_long __prog, __const u_long __vers) - __THROW; - - -/* - * Generic client creation routine. Supported protocols are "udp", "tcp" and - * "unix" - * CLIENT * - * clnt_create(host, prog, vers, prot) - * char *host; -- hostname - * u_long prog; -- program number - * u_ong vers; -- version number - * char *prot; -- protocol - */ -extern CLIENT *clnt_create (__const char *__host, __const u_long __prog, - __const u_long __vers, __const char *__prot) - __THROW; - - -/* - * TCP based rpc - * CLIENT * - * clnttcp_create(raddr, prog, vers, sockp, sendsz, recvsz) - * struct sockaddr_in *raddr; - * u_long prog; - * u_long version; - * register int *sockp; - * u_int sendsz; - * u_int recvsz; - */ -extern CLIENT *clnttcp_create (struct sockaddr_in *__raddr, u_long __prog, - u_long __version, int *__sockp, u_int __sendsz, - u_int __recvsz) __THROW; - -/* - * UDP based rpc. - * CLIENT * - * clntudp_create(raddr, program, version, wait, sockp) - * struct sockaddr_in *raddr; - * u_long program; - * u_long version; - * struct timeval wait_resend; - * int *sockp; - * - * Same as above, but you specify max packet sizes. - * CLIENT * - * clntudp_bufcreate(raddr, program, version, wait, sockp, sendsz, recvsz) - * struct sockaddr_in *raddr; - * u_long program; - * u_long version; - * struct timeval wait_resend; - * int *sockp; - * u_int sendsz; - * u_int recvsz; - */ -extern CLIENT *clntudp_create (struct sockaddr_in *__raddr, u_long __program, - u_long __version, struct timeval __wait_resend, - int *__sockp) __THROW; -extern CLIENT *clntudp_bufcreate (struct sockaddr_in *__raddr, - u_long __program, u_long __version, - struct timeval __wait_resend, int *__sockp, - u_int __sendsz, u_int __recvsz) __THROW; - - - - -/* - * AF_UNIX based rpc - * CLIENT * - * clntunix_create(raddr, prog, vers, sockp, sendsz, recvsz) - * struct sockaddr_un *raddr; - * u_long prog; - * u_long version; - * register int *sockp; - * u_int sendsz; - * u_int recvsz; - */ -extern CLIENT *clntunix_create (struct sockaddr_un *__raddr, u_long __program, - u_long __version, int *__sockp, - u_int __sendsz, u_int __recvsz) __THROW; - - -extern int callrpc (__const char *__host, __const u_long __prognum, - __const u_long __versnum, __const u_long __procnum, - __const xdrproc_t __inproc, __const char *__in, - __const xdrproc_t __outproc, char *__out) __THROW; -extern int _rpc_dtablesize (void) __THROW; - -/* - * Print why creation failed - */ -extern void clnt_pcreateerror (__const char *__msg) __THROW; /* stderr */ -extern char *clnt_spcreateerror(__const char *__msg) __THROW; /* string */ - -/* - * Like clnt_perror(), but is more verbose in its output - */ -extern void clnt_perrno (enum clnt_stat __num) __THROW; /* stderr */ - -/* - * Print an English error message, given the client error code - */ -extern void clnt_perror (CLIENT *__clnt, __const char *__msg) __THROW; - /* stderr */ -extern char *clnt_sperror (CLIENT *__clnt, __const char *__msg) __THROW; - /* string */ - -/* - * If a creation fails, the following allows the user to figure out why. - */ -struct rpc_createerr { - enum clnt_stat cf_stat; - struct rpc_err cf_error; /* useful when cf_stat == RPC_PMAPFAILURE */ -}; - -extern struct rpc_createerr rpc_createerr; - - - -/* - * Copy error message to buffer. - */ -extern char *clnt_sperrno (enum clnt_stat __num) __THROW; /* string */ - -/* - * get the port number on the host for the rpc program,version and proto - */ -extern int getrpcport (__const char * __host, u_long __prognum, - u_long __versnum, u_int proto) __THROW; - -/* - * get the local host's IP address without consulting - * name service library functions - */ -extern void get_myaddress (struct sockaddr_in *) __THROW; - -#define UDPMSGSIZE 8800 /* rpc imposed limit on udp msg size */ -#define RPCSMALLMSGSIZE 400 /* a more reasonable packet size */ - -__END_DECLS - -#endif /* rpc/clnt.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/des_crypt.h b/mdk-stage1/dietlibc/include/rpc/des_crypt.h deleted file mode 100644 index 6a65887d3..000000000 --- a/mdk-stage1/dietlibc/include/rpc/des_crypt.h +++ /dev/null @@ -1,97 +0,0 @@ -/* - * @(#)des_crypt.h 2.1 88/08/11 4.0 RPCSRC; from 1.4 88/02/08 (C) 1986 SMI - * - * des_crypt.h, des library routine interface - * Copyright (C) 1986, Sun Microsystems, Inc. - */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -#ifndef __DES_CRYPT_H__ -#define __DES_CRYPT_H__ 1 - -#include - -__BEGIN_DECLS - -#define DES_MAXDATA 8192 /* max bytes encrypted in one call */ -#define DES_DIRMASK (1 << 0) -#define DES_ENCRYPT (0*DES_DIRMASK) /* Encrypt */ -#define DES_DECRYPT (1*DES_DIRMASK) /* Decrypt */ - - -#define DES_DEVMASK (1 << 1) -#define DES_HW (0*DES_DEVMASK) /* Use hardware device */ -#define DES_SW (1*DES_DEVMASK) /* Use software device */ - - -#define DESERR_NONE 0 /* succeeded */ -#define DESERR_NOHWDEVICE 1 /* succeeded, but hw device not available */ -#define DESERR_HWERROR 2 /* failed, hardware/driver error */ -#define DESERR_BADPARAM 3 /* failed, bad parameter to call */ - -#define DES_FAILED(err) \ - ((err) > DESERR_NOHWDEVICE) - -/* - * cbc_crypt() - * ecb_crypt() - * - * Encrypt (or decrypt) len bytes of a buffer buf. - * The length must be a multiple of eight. - * The key should have odd parity in the low bit of each byte. - * ivec is the input vector, and is updated to the new one (cbc only). - * The mode is created by oring together the appropriate parameters. - * DESERR_NOHWDEVICE is returned if DES_HW was specified but - * there was no hardware to do it on (the data will still be - * encrypted though, in software). - */ - - -/* - * Cipher Block Chaining mode - */ -extern int cbc_crypt (char *__key, char *__buf, unsigned __len, - unsigned __mode, char *__ivec) __THROW; - -/* - * Electronic Code Book mode - */ -extern int ecb_crypt (char *__key, char *__buf, unsigned __len, - unsigned __mode) __THROW; - -/* - * Set des parity for a key. - * DES parity is odd and in the low bit of each byte - */ -extern void des_setparity (char *__key) __THROW; - -__END_DECLS - -#endif diff --git a/mdk-stage1/dietlibc/include/rpc/key_prot.h b/mdk-stage1/dietlibc/include/rpc/key_prot.h deleted file mode 100644 index 3e2eb7208..000000000 --- a/mdk-stage1/dietlibc/include/rpc/key_prot.h +++ /dev/null @@ -1,346 +0,0 @@ -/* - * Please do not edit this file. - * It was generated using rpcgen. - */ - -#ifndef _KEY_PROT_H_RPCGEN -#define _KEY_PROT_H_RPCGEN - -#include - -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -#if 0 -#pragma ident "@(#)key_prot.x 1.7 94/04/29 SMI" -#endif -/* Copyright (c) 1990, 1991 Sun Microsystems, Inc. */ - -/* - * Compiled from key_prot.x using rpcgen. - * DO NOT EDIT THIS FILE! - * This is NOT source code! - */ -#define PROOT 3 -#define HEXMODULUS "d4a0ba0250b6fd2ec626e7efd637df76c716e22d0944b88b" -#define HEXKEYBYTES 48 -#define KEYSIZE 192 -#define KEYBYTES 24 -#define KEYCHECKSUMSIZE 16 - -enum keystatus { - KEY_SUCCESS = 0, - KEY_NOSECRET = 1, - KEY_UNKNOWN = 2, - KEY_SYSTEMERR = 3, -}; -typedef enum keystatus keystatus; -#ifdef __cplusplus -extern "C" bool_t xdr_keystatus(XDR *, keystatus*); -#elif __STDC__ -extern bool_t xdr_keystatus(XDR *, keystatus*); -#else /* Old Style C */ -bool_t xdr_keystatus(); -#endif /* Old Style C */ - - -typedef char keybuf[HEXKEYBYTES]; -#ifdef __cplusplus -extern "C" bool_t xdr_keybuf(XDR *, keybuf); -#elif __STDC__ -extern bool_t xdr_keybuf(XDR *, keybuf); -#else /* Old Style C */ -bool_t xdr_keybuf(); -#endif /* Old Style C */ - - -typedef char *netnamestr; -#ifdef __cplusplus -extern "C" bool_t xdr_netnamestr(XDR *, netnamestr*); -#elif __STDC__ -extern bool_t xdr_netnamestr(XDR *, netnamestr*); -#else /* Old Style C */ -bool_t xdr_netnamestr(); -#endif /* Old Style C */ - - -struct cryptkeyarg { - netnamestr remotename; - des_block deskey; -}; -typedef struct cryptkeyarg cryptkeyarg; -#ifdef __cplusplus -extern "C" bool_t xdr_cryptkeyarg(XDR *, cryptkeyarg*); -#elif __STDC__ -extern bool_t xdr_cryptkeyarg(XDR *, cryptkeyarg*); -#else /* Old Style C */ -bool_t xdr_cryptkeyarg(); -#endif /* Old Style C */ - - -struct cryptkeyarg2 { - netnamestr remotename; - netobj remotekey; - des_block deskey; -}; -typedef struct cryptkeyarg2 cryptkeyarg2; -#ifdef __cplusplus -extern "C" bool_t xdr_cryptkeyarg2(XDR *, cryptkeyarg2*); -#elif __STDC__ -extern bool_t xdr_cryptkeyarg2(XDR *, cryptkeyarg2*); -#else /* Old Style C */ -bool_t xdr_cryptkeyarg2(); -#endif /* Old Style C */ - - -struct cryptkeyres { - keystatus status; - union { - des_block deskey; - } cryptkeyres_u; -}; -typedef struct cryptkeyres cryptkeyres; -#ifdef __cplusplus -extern "C" bool_t xdr_cryptkeyres(XDR *, cryptkeyres*); -#elif __STDC__ -extern bool_t xdr_cryptkeyres(XDR *, cryptkeyres*); -#else /* Old Style C */ -bool_t xdr_cryptkeyres(); -#endif /* Old Style C */ - -#define MAXGIDS 16 - -struct unixcred { - u_int uid; - u_int gid; - struct { - u_int gids_len; - u_int *gids_val; - } gids; -}; -typedef struct unixcred unixcred; -#ifdef __cplusplus -extern "C" bool_t xdr_unixcred(XDR *, unixcred*); -#elif __STDC__ -extern bool_t xdr_unixcred(XDR *, unixcred*); -#else /* Old Style C */ -bool_t xdr_unixcred(); -#endif /* Old Style C */ - - -struct getcredres { - keystatus status; - union { - unixcred cred; - } getcredres_u; -}; -typedef struct getcredres getcredres; -#ifdef __cplusplus -extern "C" bool_t xdr_getcredres(XDR *, getcredres*); -#elif __STDC__ -extern bool_t xdr_getcredres(XDR *, getcredres*); -#else /* Old Style C */ -bool_t xdr_getcredres(); -#endif /* Old Style C */ - - -struct key_netstarg { - keybuf st_priv_key; - keybuf st_pub_key; - netnamestr st_netname; -}; -typedef struct key_netstarg key_netstarg; -#ifdef __cplusplus -extern "C" bool_t xdr_key_netstarg(XDR *, key_netstarg*); -#elif __STDC__ -extern bool_t xdr_key_netstarg(XDR *, key_netstarg*); -#else /* Old Style C */ -bool_t xdr_key_netstarg(); -#endif /* Old Style C */ - - -struct key_netstres { - keystatus status; - union { - key_netstarg knet; - } key_netstres_u; -}; -typedef struct key_netstres key_netstres; -#ifdef __cplusplus -extern "C" bool_t xdr_key_netstres(XDR *, key_netstres*); -#elif __STDC__ -extern bool_t xdr_key_netstres(XDR *, key_netstres*); -#else /* Old Style C */ -bool_t xdr_key_netstres(); -#endif /* Old Style C */ - - -#ifndef opaque -#define opaque char -#endif - - -#define KEY_PROG ((u_long)100029) -#define KEY_VERS ((u_long)1) - -#ifdef __cplusplus -#define KEY_SET ((u_long)1) -extern "C" keystatus * key_set_1(opaque *, CLIENT *); -extern "C" keystatus * key_set_1_svc(opaque *, struct svc_req *); -#define KEY_ENCRYPT ((u_long)2) -extern "C" cryptkeyres * key_encrypt_1(cryptkeyarg *, CLIENT *); -extern "C" cryptkeyres * key_encrypt_1_svc(cryptkeyarg *, struct svc_req *); -#define KEY_DECRYPT ((u_long)3) -extern "C" cryptkeyres * key_decrypt_1(cryptkeyarg *, CLIENT *); -extern "C" cryptkeyres * key_decrypt_1_svc(cryptkeyarg *, struct svc_req *); -#define KEY_GEN ((u_long)4) -extern "C" des_block * key_gen_1(void *, CLIENT *); -extern "C" des_block * key_gen_1_svc(void *, struct svc_req *); -#define KEY_GETCRED ((u_long)5) -extern "C" getcredres * key_getcred_1(netnamestr *, CLIENT *); -extern "C" getcredres * key_getcred_1_svc(netnamestr *, struct svc_req *); - -#elif __STDC__ -#define KEY_SET ((u_long)1) -extern keystatus * key_set_1(opaque *, CLIENT *); -extern keystatus * key_set_1_svc(opaque *, struct svc_req *); -#define KEY_ENCRYPT ((u_long)2) -extern cryptkeyres * key_encrypt_1(cryptkeyarg *, CLIENT *); -extern cryptkeyres * key_encrypt_1_svc(cryptkeyarg *, struct svc_req *); -#define KEY_DECRYPT ((u_long)3) -extern cryptkeyres * key_decrypt_1(cryptkeyarg *, CLIENT *); -extern cryptkeyres * key_decrypt_1_svc(cryptkeyarg *, struct svc_req *); -#define KEY_GEN ((u_long)4) -extern des_block * key_gen_1(void *, CLIENT *); -extern des_block * key_gen_1_svc(void *, struct svc_req *); -#define KEY_GETCRED ((u_long)5) -extern getcredres * key_getcred_1(netnamestr *, CLIENT *); -extern getcredres * key_getcred_1_svc(netnamestr *, struct svc_req *); - -#else /* Old Style C */ -#define KEY_SET ((u_long)1) -extern keystatus * key_set_1(); -extern keystatus * key_set_1_svc(); -#define KEY_ENCRYPT ((u_long)2) -extern cryptkeyres * key_encrypt_1(); -extern cryptkeyres * key_encrypt_1_svc(); -#define KEY_DECRYPT ((u_long)3) -extern cryptkeyres * key_decrypt_1(); -extern cryptkeyres * key_decrypt_1_svc(); -#define KEY_GEN ((u_long)4) -extern des_block * key_gen_1(); -extern des_block * key_gen_1_svc(); -#define KEY_GETCRED ((u_long)5) -extern getcredres * key_getcred_1(); -extern getcredres * key_getcred_1_svc(); -#endif /* Old Style C */ -#define KEY_VERS2 ((u_long)2) - -#ifdef __cplusplus -extern "C" keystatus * key_set_2(opaque *, CLIENT *); -extern "C" keystatus * key_set_2_svc(opaque *, struct svc_req *); -extern "C" cryptkeyres * key_encrypt_2(cryptkeyarg *, CLIENT *); -extern "C" cryptkeyres * key_encrypt_2_svc(cryptkeyarg *, struct svc_req *); -extern "C" cryptkeyres * key_decrypt_2(cryptkeyarg *, CLIENT *); -extern "C" cryptkeyres * key_decrypt_2_svc(cryptkeyarg *, struct svc_req *); -extern "C" des_block * key_gen_2(void *, CLIENT *); -extern "C" des_block * key_gen_2_svc(void *, struct svc_req *); -extern "C" getcredres * key_getcred_2(netnamestr *, CLIENT *); -extern "C" getcredres * key_getcred_2_svc(netnamestr *, struct svc_req *); -#define KEY_ENCRYPT_PK ((u_long)6) -extern "C" cryptkeyres * key_encrypt_pk_2(cryptkeyarg2 *, CLIENT *); -extern "C" cryptkeyres * key_encrypt_pk_2_svc(cryptkeyarg2 *, struct svc_req *); -#define KEY_DECRYPT_PK ((u_long)7) -extern "C" cryptkeyres * key_decrypt_pk_2(cryptkeyarg2 *, CLIENT *); -extern "C" cryptkeyres * key_decrypt_pk_2_svc(cryptkeyarg2 *, struct svc_req *); -#define KEY_NET_PUT ((u_long)8) -extern "C" keystatus * key_net_put_2(key_netstarg *, CLIENT *); -extern "C" keystatus * key_net_put_2_svc(key_netstarg *, struct svc_req *); -#define KEY_NET_GET ((u_long)9) -extern "C" key_netstres * key_net_get_2(void *, CLIENT *); -extern "C" key_netstres * key_net_get_2_svc(void *, struct svc_req *); -#define KEY_GET_CONV ((u_long)10) -extern "C" cryptkeyres * key_get_conv_2(opaque *, CLIENT *); -extern "C" cryptkeyres * key_get_conv_2_svc(opaque *, struct svc_req *); - -#elif __STDC__ -extern keystatus * key_set_2(opaque *, CLIENT *); -extern keystatus * key_set_2_svc(opaque *, struct svc_req *); -extern cryptkeyres * key_encrypt_2(cryptkeyarg *, CLIENT *); -extern cryptkeyres * key_encrypt_2_svc(cryptkeyarg *, struct svc_req *); -extern cryptkeyres * key_decrypt_2(cryptkeyarg *, CLIENT *); -extern cryptkeyres * key_decrypt_2_svc(cryptkeyarg *, struct svc_req *); -extern des_block * key_gen_2(void *, CLIENT *); -extern des_block * key_gen_2_svc(void *, struct svc_req *); -extern getcredres * key_getcred_2(netnamestr *, CLIENT *); -extern getcredres * key_getcred_2_svc(netnamestr *, struct svc_req *); -#define KEY_ENCRYPT_PK ((u_long)6) -extern cryptkeyres * key_encrypt_pk_2(cryptkeyarg2 *, CLIENT *); -extern cryptkeyres * key_encrypt_pk_2_svc(cryptkeyarg2 *, struct svc_req *); -#define KEY_DECRYPT_PK ((u_long)7) -extern cryptkeyres * key_decrypt_pk_2(cryptkeyarg2 *, CLIENT *); -extern cryptkeyres * key_decrypt_pk_2_svc(cryptkeyarg2 *, struct svc_req *); -#define KEY_NET_PUT ((u_long)8) -extern keystatus * key_net_put_2(key_netstarg *, CLIENT *); -extern keystatus * key_net_put_2_svc(key_netstarg *, struct svc_req *); -#define KEY_NET_GET ((u_long)9) -extern key_netstres * key_net_get_2(void *, CLIENT *); -extern key_netstres * key_net_get_2_svc(void *, struct svc_req *); -#define KEY_GET_CONV ((u_long)10) -extern cryptkeyres * key_get_conv_2(opaque *, CLIENT *); -extern cryptkeyres * key_get_conv_2_svc(opaque *, struct svc_req *); - -#else /* Old Style C */ -extern keystatus * key_set_2(); -extern keystatus * key_set_2_svc(); -extern cryptkeyres * key_encrypt_2(); -extern cryptkeyres * key_encrypt_2_svc(); -extern cryptkeyres * key_decrypt_2(); -extern cryptkeyres * key_decrypt_2_svc(); -extern des_block * key_gen_2(); -extern des_block * key_gen_2_svc(); -extern getcredres * key_getcred_2(); -extern getcredres * key_getcred_2_svc(); -#define KEY_ENCRYPT_PK ((u_long)6) -extern cryptkeyres * key_encrypt_pk_2(); -extern cryptkeyres * key_encrypt_pk_2_svc(); -#define KEY_DECRYPT_PK ((u_long)7) -extern cryptkeyres * key_decrypt_pk_2(); -extern cryptkeyres * key_decrypt_pk_2_svc(); -#define KEY_NET_PUT ((u_long)8) -extern keystatus * key_net_put_2(); -extern keystatus * key_net_put_2_svc(); -#define KEY_NET_GET ((u_long)9) -extern key_netstres * key_net_get_2(); -extern key_netstres * key_net_get_2_svc(); -#define KEY_GET_CONV ((u_long)10) -extern cryptkeyres * key_get_conv_2(); -extern cryptkeyres * key_get_conv_2_svc(); -#endif /* Old Style C */ - -#endif /* !_KEY_PROT_H_RPCGEN */ diff --git a/mdk-stage1/dietlibc/include/rpc/netdb.h b/mdk-stage1/dietlibc/include/rpc/netdb.h deleted file mode 100644 index da4bddfc4..000000000 --- a/mdk-stage1/dietlibc/include/rpc/netdb.h +++ /dev/null @@ -1,74 +0,0 @@ -/* @(#)netdb.h 2.1 88/07/29 3.9 RPCSRC */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* @(#)rpc.h 1.8 87/07/24 SMI */ - -/* Cleaned up for GNU C library roland@gnu.ai.mit.edu: - added multiple inclusion protection and use of . - In GNU this file is #include'd by . */ - -#ifndef _RPC_NETDB_H -#define _RPC_NETDB_H 1 - -#include - -#define __need_size_t -#include - -__BEGIN_DECLS - -struct rpcent -{ - char *r_name; /* Name of server for this rpc program. */ - char **r_aliases; /* Alias list. */ - int r_number; /* RPC program number. */ -}; - -extern void setrpcent (int __stayopen) __THROW; -extern void endrpcent (void) __THROW; -extern struct rpcent *getrpcbyname (__const char *__name) __THROW; -extern struct rpcent *getrpcbynumber (int __number) __THROW; -extern struct rpcent *getrpcent (void) __THROW; - -#ifdef __USE_MISC -extern int getrpcbyname_r (__const char *__name, struct rpcent *__result_buf, - char *__buffer, size_t __buflen, - struct rpcent **__result) __THROW; - -extern int getrpcbynumber_r (int __number, struct rpcent *__result_buf, - char *__buffer, size_t __buflen, - struct rpcent **__result) __THROW; - -extern int getrpcent_r (struct rpcent *__result_buf, char *__buffer, - size_t __buflen, struct rpcent **__result) __THROW; -#endif - -__END_DECLS - -#endif /* rpc/netdb.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/pmap_clnt.h b/mdk-stage1/dietlibc/include/rpc/pmap_clnt.h deleted file mode 100644 index 68bc8d8ec..000000000 --- a/mdk-stage1/dietlibc/include/rpc/pmap_clnt.h +++ /dev/null @@ -1,98 +0,0 @@ -/* @(#)pmap_clnt.h 2.1 88/07/29 4.0 RPCSRC; from 1.11 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * pmap_clnt.h - * Supplies C routines to get to portmap services. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_PMAP_CLNT_H -#define _RPC_PMAP_CLNT_H 1 - -#include -#include -#include -#include - -__BEGIN_DECLS - -typedef bool_t (*resultproc_t) (caddr_t resp, struct sockaddr_in *raddr); - -/* - * Usage: - * success = pmap_set(program, version, protocol, port); - * success = pmap_unset(program, version); - * port = pmap_getport(address, program, version, protocol); - * head = pmap_getmaps(address); - * clnt_stat = pmap_rmtcall(address, program, version, procedure, - * xdrargs, argsp, xdrres, resp, tout, port_ptr) - * (works for udp only.) - * clnt_stat = clnt_broadcast(program, version, procedure, - * xdrargs, argsp, xdrres, resp, eachresult) - * (like pmap_rmtcall, except the call is broadcasted to all - * locally connected nets. For each valid response received, - * the procedure eachresult is called. Its form is: - * done = eachresult(resp, raddr) - * bool_t done; - * caddr_t resp; - * struct sockaddr_in raddr; - * where resp points to the results of the call and raddr is the - * address if the responder to the broadcast. - */ - -extern bool_t pmap_set (__const u_long __program, __const u_long __vers, - int __protocol, u_short __port) __THROW; -extern bool_t pmap_unset (__const u_long __program, __const u_long __vers) - __THROW; -extern struct pmaplist *pmap_getmaps (struct sockaddr_in *__address) __THROW; -extern enum clnt_stat pmap_rmtcall (struct sockaddr_in *__addr, - __const u_long __prog, - __const u_long __vers, - __const u_long __proc, - xdrproc_t __xdrargs, - caddr_t __argsp, xdrproc_t __xdrres, - caddr_t __resp, struct timeval __tout, - u_long *__port_ptr) __THROW; -extern enum clnt_stat clnt_broadcast (__const u_long __prog, - __const u_long __vers, - __const u_long __proc, xdrproc_t __xargs, - caddr_t __argsp, xdrproc_t __xresults, - caddr_t __resultsp, - resultproc_t __eachresult) __THROW; -extern u_short pmap_getport (struct sockaddr_in *__address, - __const u_long __program, - __const u_long __version, u_int __protocol) - __THROW; - -__END_DECLS - -#endif /* rpc/pmap_clnt.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/pmap_prot.h b/mdk-stage1/dietlibc/include/rpc/pmap_prot.h deleted file mode 100644 index fd7fb8e7e..000000000 --- a/mdk-stage1/dietlibc/include/rpc/pmap_prot.h +++ /dev/null @@ -1,108 +0,0 @@ -/* @(#)pmap_prot.h 2.1 88/07/29 4.0 RPCSRC; from 1.14 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * pmap_prot.h - * Protocol for the local binder service, or pmap. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_PMAP_PROT_H -#define _RPC_PMAP_PROT_H 1 - -#include - -#include - -__BEGIN_DECLS - -/* The following procedures are supported by the protocol: - * - * PMAPPROC_NULL() returns () - * takes nothing, returns nothing - * - * PMAPPROC_SET(struct pmap) returns (bool_t) - * TRUE is success, FALSE is failure. Registers the tuple - * [prog, vers, prot, port]. - * - * PMAPPROC_UNSET(struct pmap) returns (bool_t) - * TRUE is success, FALSE is failure. Un-registers pair - * [prog, vers]. prot and port are ignored. - * - * PMAPPROC_GETPORT(struct pmap) returns (long unsigned). - * 0 is failure. Otherwise returns the port number where the pair - * [prog, vers] is registered. It may lie! - * - * PMAPPROC_DUMP() RETURNS (struct pmaplist *) - * - * PMAPPROC_CALLIT(unsigned, unsigned, unsigned, string<>) - * RETURNS (port, string<>); - * usage: encapsulatedresults = PMAPPROC_CALLIT(prog, vers, proc, encapsulatedargs); - * Calls the procedure on the local machine. If it is not registered, - * this procedure is quite; ie it does not return error information!!! - * This procedure only is supported on rpc/udp and calls via - * rpc/udp. This routine only passes null authentication parameters. - * This file has no interface to xdr routines for PMAPPROC_CALLIT. - * - * The service supports remote procedure calls on udp/ip or tcp/ip socket 111. - */ - -#define PMAPPORT ((u_short)111) -#define PMAPPROG ((u_long)100000) -#define PMAPVERS ((u_long)2) -#define PMAPVERS_PROTO ((u_long)2) -#define PMAPVERS_ORIG ((u_long)1) -#define PMAPPROC_NULL ((u_long)0) -#define PMAPPROC_SET ((u_long)1) -#define PMAPPROC_UNSET ((u_long)2) -#define PMAPPROC_GETPORT ((u_long)3) -#define PMAPPROC_DUMP ((u_long)4) -#define PMAPPROC_CALLIT ((u_long)5) - -struct pmap { - long unsigned pm_prog; - long unsigned pm_vers; - long unsigned pm_prot; - long unsigned pm_port; -}; - -extern bool_t xdr_pmap (XDR *__xdrs, struct pmap *__regs) __THROW; - -struct pmaplist { - struct pmap pml_map; - struct pmaplist *pml_next; -}; - -extern bool_t xdr_pmaplist (XDR *__xdrs, struct pmaplist **__rp) __THROW; - -__END_DECLS - -#endif /* rpc/pmap_prot.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/pmap_rmt.h b/mdk-stage1/dietlibc/include/rpc/pmap_rmt.h deleted file mode 100644 index 160f998ca..000000000 --- a/mdk-stage1/dietlibc/include/rpc/pmap_rmt.h +++ /dev/null @@ -1,68 +0,0 @@ -/* @(#)pmap_rmt.h 2.1 88/07/29 4.0 RPCSRC; from 1.2 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * Structures and XDR routines for parameters to and replies from - * the portmapper remote-call-service. - * - * Copyright (C) 1986, Sun Microsystems, Inc. - */ - -#ifndef _RPC_PMAP_RMT_H -#define _RPC_PMAP_RMT_H 1 - -#include -#include -#include -#include - -__BEGIN_DECLS - -struct rmtcallargs { - u_long prog, vers, proc, arglen; - caddr_t args_ptr; - xdrproc_t xdr_args; -}; - -extern bool_t xdr_rmtcall_args (XDR *__xdrs, struct rmtcallargs *__crp) - __THROW; - -struct rmtcallres { - u_long *port_ptr; - u_long resultslen; - caddr_t results_ptr; - xdrproc_t xdr_results; -}; - -extern bool_t xdr_rmtcallres (XDR *__xdrs, struct rmtcallres *__crp) __THROW; - -__END_DECLS - -#endif /* rpc/pmap_rmt.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/rpc.h b/mdk-stage1/dietlibc/include/rpc/rpc.h deleted file mode 100644 index 20b341d74..000000000 --- a/mdk-stage1/dietlibc/include/rpc/rpc.h +++ /dev/null @@ -1,72 +0,0 @@ -/* @(#)rpc.h 2.3 88/08/10 4.0 RPCSRC; from 1.9 88/02/08 SMI */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * rpc.h, Just includes the billions of rpc header files necessary to - * do remote procedure calling. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_RPC_H -#define _RPC_RPC_H 1 - -#include /* some typedefs */ -#include - -/* external data representation interfaces */ -#include /* generic (de)serializer */ - -/* Client side only authentication */ -#include /* generic authenticator (client side) */ - -/* Client side (mostly) remote procedure call */ -#include /* generic rpc stuff */ - -/* semi-private protocol headers */ -#include /* protocol for rpc messages */ -#include /* protocol for unix style cred */ -#include /* protocol for des style cred */ - -/* Server side only remote procedure callee */ -#include /* service manager and multiplexer */ -#include /* service side authenticator */ - -/* - * COMMENT OUT THE NEXT INCLUDE IF RUNNING ON SUN OS OR ON A VERSION - * OF UNIX BASED ON NFSSRC. These systems will already have the structures - * defined by included in . - */ -/* routines for parsing /etc/rpc */ -#include /* structures and routines to parse /etc/rpc */ - -int bindresvport(int sd, struct sockaddr_in* sin) __THROW; - -#endif /* rpc/rpc.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/rpc_des.h b/mdk-stage1/dietlibc/include/rpc/rpc_des.h deleted file mode 100644 index 0f36d1697..000000000 --- a/mdk-stage1/dietlibc/include/rpc/rpc_des.h +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* - * Generic DES driver interface - * Keep this file hardware independent! - * Copyright (c) 1986 by Sun Microsystems, Inc. - */ - -#ifndef _DES_H -#define _DES_H - -#include - -#define DES_MAXLEN 65536 /* maximum # of bytes to encrypt */ -#define DES_QUICKLEN 16 /* maximum # of bytes to encrypt quickly */ - -enum desdir - { - ENCRYPT, DECRYPT - }; -enum desmode - { - CBC, ECB - }; - -/* - * parameters to ioctl call - */ -struct desparams - { - u_char des_key[8]; /* key (with low bit parity) */ - enum desdir des_dir; /* direction */ - enum desmode des_mode; /* mode */ - u_char des_ivec[8]; /* input vector */ - unsigned des_len; /* number of bytes to crypt */ - union - { - u_char UDES_data[DES_QUICKLEN]; - u_char *UDES_buf; - } - UDES; -#define des_data UDES.UDES_data /* direct data here if quick */ -#define des_buf UDES.UDES_buf /* otherwise, pointer to data */ - }; - -#endif diff --git a/mdk-stage1/dietlibc/include/rpc/rpc_msg.h b/mdk-stage1/dietlibc/include/rpc/rpc_msg.h deleted file mode 100644 index 636d60ea9..000000000 --- a/mdk-stage1/dietlibc/include/rpc/rpc_msg.h +++ /dev/null @@ -1,202 +0,0 @@ -/* @(#)rpc_msg.h 2.1 88/07/29 4.0 RPCSRC */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* @(#)rpc_msg.h 1.7 86/07/16 SMI */ - -#ifndef _RPC_MSG_H -#define _RPC_MSG_H 1 - -#include - -#include -#include - -/* - * rpc_msg.h - * rpc message definition - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#define RPC_MSG_VERSION ((u_long) 2) -#define RPC_SERVICE_PORT ((u_short) 2048) - -__BEGIN_DECLS - -/* - * Bottom up definition of an rpc message. - * NOTE: call and reply use the same overall struct but - * different parts of unions within it. - */ - -enum msg_type { - CALL=0, - REPLY=1 -}; - -enum reply_stat { - MSG_ACCEPTED=0, - MSG_DENIED=1 -}; - -enum accept_stat { - SUCCESS=0, - PROG_UNAVAIL=1, - PROG_MISMATCH=2, - PROC_UNAVAIL=3, - GARBAGE_ARGS=4, - SYSTEM_ERR=5 -}; - -enum reject_stat { - RPC_MISMATCH=0, - AUTH_ERROR=1 -}; - -/* - * Reply part of an rpc exchange - */ - -/* - * Reply to an rpc request that was accepted by the server. - * Note: there could be an error even though the request was - * accepted. - */ -struct accepted_reply { - struct opaque_auth ar_verf; - enum accept_stat ar_stat; - union { - struct { - u_long low; - u_long high; - } AR_versions; - struct { - caddr_t where; - xdrproc_t proc; - } AR_results; - /* and many other null cases */ - } ru; -#define ar_results ru.AR_results -#define ar_vers ru.AR_versions -}; - -/* - * Reply to an rpc request that was rejected by the server. - */ -struct rejected_reply { - enum reject_stat rj_stat; - union { - struct { - u_long low; - u_long high; - } RJ_versions; - enum auth_stat RJ_why; /* why authentication did not work */ - } ru; -#define rj_vers ru.RJ_versions -#define rj_why ru.RJ_why -}; - -/* - * Body of a reply to an rpc request. - */ -struct reply_body { - enum reply_stat rp_stat; - union { - struct accepted_reply RP_ar; - struct rejected_reply RP_dr; - } ru; -#define rp_acpt ru.RP_ar -#define rp_rjct ru.RP_dr -}; - -/* - * Body of an rpc request call. - */ -struct call_body { - u_long cb_rpcvers; /* must be equal to two */ - u_long cb_prog; - u_long cb_vers; - u_long cb_proc; - struct opaque_auth cb_cred; - struct opaque_auth cb_verf; /* protocol specific - provided by client */ -}; - -/* - * The rpc message - */ -struct rpc_msg { - u_long rm_xid; - enum msg_type rm_direction; - union { - struct call_body RM_cmb; - struct reply_body RM_rmb; - } ru; -#define rm_call ru.RM_cmb -#define rm_reply ru.RM_rmb -}; -#define acpted_rply ru.RM_rmb.ru.RP_ar -#define rjcted_rply ru.RM_rmb.ru.RP_dr - - -/* - * XDR routine to handle a rpc message. - * xdr_callmsg(xdrs, cmsg) - * XDR *xdrs; - * struct rpc_msg *cmsg; - */ -extern bool_t xdr_callmsg (XDR *__xdrs, struct rpc_msg *__cmsg) __THROW; - -/* - * XDR routine to pre-serialize the static part of a rpc message. - * xdr_callhdr(xdrs, cmsg) - * XDR *xdrs; - * struct rpc_msg *cmsg; - */ -extern bool_t xdr_callhdr (XDR *__xdrs, struct rpc_msg *__cmsg) __THROW; - -/* - * XDR routine to handle a rpc reply. - * xdr_replymsg(xdrs, rmsg) - * XDR *xdrs; - * struct rpc_msg *rmsg; - */ -extern bool_t xdr_replymsg (XDR *__xdrs, struct rpc_msg *__rmsg) __THROW; - -/* - * Fills in the error part of a reply message. - * _seterr_reply(msg, error) - * struct rpc_msg *msg; - * struct rpc_err *error; - */ -extern void _seterr_reply (struct rpc_msg *__msg, struct rpc_err *__error) - __THROW; - -__END_DECLS - -#endif /* rpc/rpc_msg.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/svc.h b/mdk-stage1/dietlibc/include/rpc/svc.h deleted file mode 100644 index 27c997dde..000000000 --- a/mdk-stage1/dietlibc/include/rpc/svc.h +++ /dev/null @@ -1,316 +0,0 @@ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * svc.h, Server-side remote procedure call interface. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_SVC_H -#define _RPC_SVC_H 1 - -#include -#include - -__BEGIN_DECLS - -/* - * This interface must manage two items concerning remote procedure calling: - * - * 1) An arbitrary number of transport connections upon which rpc requests - * are received. The two most notable transports are TCP and UDP; they are - * created and registered by routines in svc_tcp.c and svc_udp.c, respectively; - * they in turn call xprt_register and xprt_unregister. - * - * 2) An arbitrary number of locally registered services. Services are - * described by the following four data: program number, version number, - * "service dispatch" function, a transport handle, and a boolean that - * indicates whether or not the exported program should be registered with a - * local binder service; if true the program's number and version and the - * port number from the transport handle are registered with the binder. - * These data are registered with the rpc svc system via svc_register. - * - * A service's dispatch function is called whenever an rpc request comes in - * on a transport. The request's program and version numbers must match - * those of the registered service. The dispatch function is passed two - * parameters, struct svc_req * and SVCXPRT *, defined below. - */ - -enum xprt_stat { - XPRT_DIED, - XPRT_MOREREQS, - XPRT_IDLE -}; - -/* - * Server side transport handle - */ -typedef struct SVCXPRT SVCXPRT; -struct SVCXPRT { - int xp_sock; - u_short xp_port; /* associated port number */ - const struct xp_ops { - bool_t (*xp_recv) (SVCXPRT *__xprt, struct rpc_msg *__msg); - /* receive incoming requests */ - enum xprt_stat (*xp_stat) (SVCXPRT *__xprt); - /* get transport status */ - bool_t (*xp_getargs) (SVCXPRT *__xprt, xdrproc_t __xdr_args, - caddr_t args_ptr); /* get arguments */ - bool_t (*xp_reply) (SVCXPRT *__xprt, struct rpc_msg *__msg); - /* send reply */ - bool_t (*xp_freeargs) (SVCXPRT *__xprt, xdrproc_t __xdr_args, - caddr_t args_ptr); - /* free mem allocated for args */ - void (*xp_destroy) (SVCXPRT *__xprt); - /* destroy this struct */ - } *xp_ops; - int xp_addrlen; /* length of remote address */ - struct sockaddr_in xp_raddr; /* remote address */ - struct opaque_auth xp_verf; /* raw response verifier */ - caddr_t xp_p1; /* private */ - caddr_t xp_p2; /* private */ - char xp_pad [256]; /* padding, internal use */ -}; - -/* - * Approved way of getting address of caller - */ -#define svc_getcaller(x) (&(x)->xp_raddr) - -/* - * Operations defined on an SVCXPRT handle - * - * SVCXPRT *xprt; - * struct rpc_msg *msg; - * xdrproc_t xargs; - * caddr_t argsp; - */ -#define SVC_RECV(xprt, msg) \ - (*(xprt)->xp_ops->xp_recv)((xprt), (msg)) -#define svc_recv(xprt, msg) \ - (*(xprt)->xp_ops->xp_recv)((xprt), (msg)) - -#define SVC_STAT(xprt) \ - (*(xprt)->xp_ops->xp_stat)(xprt) -#define svc_stat(xprt) \ - (*(xprt)->xp_ops->xp_stat)(xprt) - -#define SVC_GETARGS(xprt, xargs, argsp) \ - (*(xprt)->xp_ops->xp_getargs)((xprt), (xargs), (argsp)) -#define svc_getargs(xprt, xargs, argsp) \ - (*(xprt)->xp_ops->xp_getargs)((xprt), (xargs), (argsp)) - -#define SVC_REPLY(xprt, msg) \ - (*(xprt)->xp_ops->xp_reply) ((xprt), (msg)) -#define svc_reply(xprt, msg) \ - (*(xprt)->xp_ops->xp_reply) ((xprt), (msg)) - -#define SVC_FREEARGS(xprt, xargs, argsp) \ - (*(xprt)->xp_ops->xp_freeargs)((xprt), (xargs), (argsp)) -#define svc_freeargs(xprt, xargs, argsp) \ - (*(xprt)->xp_ops->xp_freeargs)((xprt), (xargs), (argsp)) - -#define SVC_DESTROY(xprt) \ - (*(xprt)->xp_ops->xp_destroy)(xprt) -#define svc_destroy(xprt) \ - (*(xprt)->xp_ops->xp_destroy)(xprt) - - -/* - * Service request - */ -struct svc_req { - rpcprog_t rq_prog; /* service program number */ - rpcvers_t rq_vers; /* service protocol version */ - rpcproc_t rq_proc; /* the desired procedure */ - struct opaque_auth rq_cred; /* raw creds from the wire */ - caddr_t rq_clntcred; /* read only cooked cred */ - SVCXPRT *rq_xprt; /* associated transport */ -}; - -#ifndef __DISPATCH_FN_T -#define __DISPATCH_FN_T -typedef void (*__dispatch_fn_t) (struct svc_req*, SVCXPRT*); -#endif - -/* - * Service registration - * - * svc_register(xprt, prog, vers, dispatch, protocol) - * SVCXPRT *xprt; - * rpcprog_t prog; - * rpcvers_t vers; - * void (*dispatch)(struct svc_req*, SVCXPRT*); - * rpcprot_t protocol; like TCP or UDP, zero means do not register - */ -extern bool_t svc_register (SVCXPRT *__xprt, rpcprog_t __prog, - rpcvers_t __vers, __dispatch_fn_t __dispatch, - rpcprot_t __protocol) __THROW; - -/* - * Service un-registration - * - * svc_unregister(prog, vers) - * rpcprog_t prog; - * rpcvers_t vers; - */ -extern void svc_unregister (rpcprog_t __prog, rpcvers_t __vers) __THROW; - -/* - * Transport registration. - * - * xprt_register(xprt) - * SVCXPRT *xprt; - */ -extern void xprt_register (SVCXPRT *__xprt) __THROW; - -/* - * Transport un-register - * - * xprt_unregister(xprt) - * SVCXPRT *xprt; - */ -extern void xprt_unregister (SVCXPRT *__xprt) __THROW; - - -/* - * When the service routine is called, it must first check to see if it - * knows about the procedure; if not, it should call svcerr_noproc - * and return. If so, it should deserialize its arguments via - * SVC_GETARGS (defined above). If the deserialization does not work, - * svcerr_decode should be called followed by a return. Successful - * decoding of the arguments should be followed the execution of the - * procedure's code and a call to svc_sendreply. - * - * Also, if the service refuses to execute the procedure due to too- - * weak authentication parameters, svcerr_weakauth should be called. - * Note: do not confuse access-control failure with weak authentication! - * - * NB: In pure implementations of rpc, the caller always waits for a reply - * msg. This message is sent when svc_sendreply is called. - * Therefore pure service implementations should always call - * svc_sendreply even if the function logically returns void; use - * xdr.h - xdr_void for the xdr routine. HOWEVER, tcp based rpc allows - * for the abuse of pure rpc via batched calling or pipelining. In the - * case of a batched call, svc_sendreply should NOT be called since - * this would send a return message, which is what batching tries to avoid. - * It is the service/protocol writer's responsibility to know which calls are - * batched and which are not. Warning: responding to batch calls may - * deadlock the caller and server processes! - */ - -extern bool_t svc_sendreply (SVCXPRT *xprt, xdrproc_t __xdr_results, - caddr_t __xdr_location) __THROW; - -extern void svcerr_decode (SVCXPRT *__xprt) __THROW; - -extern void svcerr_weakauth (SVCXPRT *__xprt) __THROW; - -extern void svcerr_noproc (SVCXPRT *__xprt) __THROW; - -extern void svcerr_progvers (SVCXPRT *__xprt, rpcvers_t __low_vers, - rpcvers_t __high_vers) __THROW; - -extern void svcerr_auth (SVCXPRT *__xprt, enum auth_stat __why) __THROW; - -extern void svcerr_noprog (SVCXPRT *__xprt) __THROW; - -extern void svcerr_systemerr (SVCXPRT *__xprt) __THROW; - -/* - * Lowest level dispatching -OR- who owns this process anyway. - * Somebody has to wait for incoming requests and then call the correct - * service routine. The routine svc_run does infinite waiting; i.e., - * svc_run never returns. - * Since another (coexistent) package may wish to selectively wait for - * incoming calls or other events outside of the rpc architecture, the - * routine svc_getreq is provided. It must be passed readfds, the - * "in-place" results of a select system call (see select, section 2). - */ - -/* - * Global keeper of rpc service descriptors in use - * dynamic; must be inspected before each call to select - */ - -extern struct pollfd *svc_pollfd; -extern int svc_max_pollfd; -extern fd_set svc_fdset; -#define svc_fds svc_fdset.fds_bits[0] /* compatibility */ - -/* - * a small program implemented by the svc_rpc implementation itself; - * also see clnt.h for protocol numbers. - */ -extern void svc_getreq (int __rdfds) __THROW; -extern void svc_getreq_common (const int __fd) __THROW; -extern void svc_getreqset (fd_set *__readfds) __THROW; -extern void svc_getreq_poll (struct pollfd *, const int) __THROW; -extern void svc_exit (void) __THROW; -extern void svc_run (void) __THROW; - -/* - * Socket to use on svcxxx_create call to get default socket - */ -#define RPC_ANYSOCK -1 - -/* - * These are the existing service side transport implementations - */ - -/* - * Memory based rpc for testing and timing. - */ -extern SVCXPRT *svcraw_create (void) __THROW; - -/* - * Udp based rpc. - */ -extern SVCXPRT *svcudp_create (int __sock) __THROW; -extern SVCXPRT *svcudp_bufcreate (int __sock, u_int __sendsz, u_int __recvsz) - __THROW; - -/* - * Tcp based rpc. - */ -extern SVCXPRT *svctcp_create (int __sock, u_int __sendsize, u_int __recvsize) - __THROW; - - -/* - * Unix based rpc. - */ -extern SVCXPRT *svcunix_create (int __sock, u_int __sendsize, u_int __recvsize, - char *__path) __THROW; - - -__END_DECLS - -#endif /* rpc/svc.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/svc_auth.h b/mdk-stage1/dietlibc/include/rpc/svc_auth.h deleted file mode 100644 index cd4b8da29..000000000 --- a/mdk-stage1/dietlibc/include/rpc/svc_auth.h +++ /dev/null @@ -1,54 +0,0 @@ -/* @(#)svc_auth.h 2.1 88/07/29 4.0 RPCSRC */ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* @(#)svc_auth.h 1.6 86/07/16 SMI */ - -/* - * svc_auth.h, Service side of rpc authentication. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_SVC_AUTH_H -#define _RPC_SVC_AUTH_H 1 - -#include -#include - -__BEGIN_DECLS - -/* - * Server side authenticator - */ -extern enum auth_stat _authenticate (struct svc_req *__rqst, - struct rpc_msg *__msg) __THROW; - -__END_DECLS - -#endif /* rpc/svc_auth.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/types.h b/mdk-stage1/dietlibc/include/rpc/types.h deleted file mode 100644 index e2e8402be..000000000 --- a/mdk-stage1/dietlibc/include/rpc/types.h +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ -/* fixincludes should not add extern "C" to this file */ -/* - * Rpc additions to - */ -#ifndef _RPC_TYPES_H -#define _RPC_TYPES_H 1 - -typedef int bool_t; -typedef int enum_t; -/* This needs to be changed to uint32_t in the future */ -typedef unsigned long rpcprog_t; -typedef unsigned long rpcvers_t; -typedef unsigned long rpcproc_t; -typedef unsigned long rpcprot_t; -typedef unsigned long rpcport_t; - -#define __dontcare__ -1 - -#ifndef FALSE -# define FALSE (0) -#endif - -#ifndef TRUE -# define TRUE (1) -#endif - -#ifndef NULL -# define NULL 0 -#endif - -#include /* For malloc decl. */ -#define mem_alloc(bsize) malloc(bsize) -#define mem_free(ptr, bsize) free(ptr) - -#ifndef makedev /* ie, we haven't already included it */ -#include -#endif -#include -#include - -#include - -#ifndef INADDR_LOOPBACK -#define INADDR_LOOPBACK (u_long)0x7F000001 -#endif -#ifndef MAXHOSTNAMELEN -#define MAXHOSTNAMELEN 64 -#endif - -#endif /* rpc/types.h */ diff --git a/mdk-stage1/dietlibc/include/rpc/xdr.h b/mdk-stage1/dietlibc/include/rpc/xdr.h deleted file mode 100644 index ce092f085..000000000 --- a/mdk-stage1/dietlibc/include/rpc/xdr.h +++ /dev/null @@ -1,379 +0,0 @@ -/* - * Sun RPC is a product of Sun Microsystems, Inc. and is provided for - * unrestricted use provided that this legend is included on all tape - * media and as a part of the software program in whole or part. Users - * may copy or modify Sun RPC without charge, but are not authorized - * to license or distribute it to anyone else except as part of a product or - * program developed by the user. - * - * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE - * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR - * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * - * Sun RPC is provided with no support and without any obligation on the - * part of Sun Microsystems, Inc. to assist in its use, correction, - * modification or enhancement. - * - * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE - * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC - * OR ANY PART THEREOF. - * - * In no event will Sun Microsystems, Inc. be liable for any lost revenue - * or profits or other special, indirect and consequential damages, even if - * Sun has been advised of the possibility of such damages. - * - * Sun Microsystems, Inc. - * 2550 Garcia Avenue - * Mountain View, California 94043 - */ - -/* - * xdr.h, External Data Representation Serialization Routines. - * - * Copyright (C) 1984, Sun Microsystems, Inc. - */ - -#ifndef _RPC_XDR_H -#define _RPC_XDR_H 1 - -#include -#include -#include - -/* We need FILE. */ -#include - -__BEGIN_DECLS - -/* - * XDR provides a conventional way for converting between C data - * types and an external bit-string representation. Library supplied - * routines provide for the conversion on built-in C data types. These - * routines and utility routines defined here are used to help implement - * a type encode/decode routine for each user-defined type. - * - * Each data type provides a single procedure which takes two arguments: - * - * bool_t - * xdrproc(xdrs, argresp) - * XDR *xdrs; - * *argresp; - * - * xdrs is an instance of a XDR handle, to which or from which the data - * type is to be converted. argresp is a pointer to the structure to be - * converted. The XDR handle contains an operation field which indicates - * which of the operations (ENCODE, DECODE * or FREE) is to be performed. - * - * XDR_DECODE may allocate space if the pointer argresp is null. This - * data can be freed with the XDR_FREE operation. - * - * We write only one procedure per data type to make it easy - * to keep the encode and decode procedures for a data type consistent. - * In many cases the same code performs all operations on a user defined type, - * because all the hard work is done in the component type routines. - * decode as a series of calls on the nested data types. - */ - -/* - * Xdr operations. XDR_ENCODE causes the type to be encoded into the - * stream. XDR_DECODE causes the type to be extracted from the stream. - * XDR_FREE can be used to release the space allocated by an XDR_DECODE - * request. - */ -enum xdr_op { - XDR_ENCODE = 0, - XDR_DECODE = 1, - XDR_FREE = 2 -}; - -/* - * This is the number of bytes per unit of external data. - */ -#define BYTES_PER_XDR_UNIT (4) -/* - * This only works if the above is a power of 2. But it's defined to be - * 4 by the appropriate RFCs. So it will work. And it's normally quicker - * than the old routine. - */ -#if 1 -#define RNDUP(x) (((x) + BYTES_PER_XDR_UNIT - 1) & ~(BYTES_PER_XDR_UNIT - 1)) -#else /* this is the old routine */ -#define RNDUP(x) ((((x) + BYTES_PER_XDR_UNIT - 1) / BYTES_PER_XDR_UNIT) \ - * BYTES_PER_XDR_UNIT) -#endif - -/* - * The XDR handle. - * Contains operation which is being applied to the stream, - * an operations vector for the particular implementation (e.g. see xdr_mem.c), - * and two private fields for the use of the particular implementation. - */ -typedef struct XDR XDR; -struct XDR - { - enum xdr_op x_op; /* operation; fast additional param */ - struct xdr_ops - { - bool_t (*x_getlong) (XDR *__xdrs, long *__lp); - /* get a long from underlying stream */ - bool_t (*x_putlong) (XDR *__xdrs, const long *__lp); - /* put a long to " */ - bool_t (*x_getbytes) (XDR *__xdrs, caddr_t __addr, u_int __len); - /* get some bytes from " */ - bool_t (*x_putbytes) (XDR *__xdrs, const char *__addr, u_int __len); - /* put some bytes to " */ - u_int (*x_getpostn) (const XDR *__xdrs); - /* returns bytes off from beginning */ - bool_t (*x_setpostn) (XDR *__xdrs, u_int __pos); - /* lets you reposition the stream */ - int32_t *(*x_inline) (XDR *__xdrs, int __len); - /* buf quick ptr to buffered data */ - void (*x_destroy) (XDR *__xdrs); - /* free privates of this xdr_stream */ - bool_t (*x_getint32) (XDR *__xdrs, int32_t *__ip); - /* get a int from underlying stream */ - bool_t (*x_putint32) (XDR *__xdrs, const int32_t *__ip); - /* put a int to " */ - } - *x_ops; - caddr_t x_public; /* users' data */ - caddr_t x_private; /* pointer to private data */ - caddr_t x_base; /* private used for position info */ - int x_handy; /* extra private word */ - }; - -/* - * A xdrproc_t exists for each data type which is to be encoded or decoded. - * - * The second argument to the xdrproc_t is a pointer to an opaque pointer. - * The opaque pointer generally points to a structure of the data type - * to be decoded. If this pointer is 0, then the type routines should - * allocate dynamic storage of the appropriate size and return it. - * bool_t (*xdrproc_t)(XDR *, caddr_t *); - */ -typedef bool_t (*xdrproc_t) (XDR *, void *,...); - - -/* - * Operations defined on a XDR handle - * - * XDR *xdrs; - * int32_t *int32p; - * long *longp; - * caddr_t addr; - * u_int len; - * u_int pos; - */ -#define XDR_GETINT32(xdrs, int32p) \ - (*(xdrs)->x_ops->x_getint32)(xdrs, int32p) -#define xdr_getint32(xdrs, int32p) \ - (*(xdrs)->x_ops->x_getint32)(xdrs, int32p) - -#define XDR_PUTINT32(xdrs, int32p) \ - (*(xdrs)->x_ops->x_putint32)(xdrs, int32p) -#define xdr_putint32(xdrs, int32p) \ - (*(xdrs)->x_ops->x_putint32)(xdrs, int32p) - -#define XDR_GETLONG(xdrs, longp) \ - (*(xdrs)->x_ops->x_getlong)(xdrs, longp) -#define xdr_getlong(xdrs, longp) \ - (*(xdrs)->x_ops->x_getlong)(xdrs, longp) - -#define XDR_PUTLONG(xdrs, longp) \ - (*(xdrs)->x_ops->x_putlong)(xdrs, longp) -#define xdr_putlong(xdrs, longp) \ - (*(xdrs)->x_ops->x_putlong)(xdrs, longp) - -#define XDR_GETBYTES(xdrs, addr, len) \ - (*(xdrs)->x_ops->x_getbytes)(xdrs, addr, len) -#define xdr_getbytes(xdrs, addr, len) \ - (*(xdrs)->x_ops->x_getbytes)(xdrs, addr, len) - -#define XDR_PUTBYTES(xdrs, addr, len) \ - (*(xdrs)->x_ops->x_putbytes)(xdrs, addr, len) -#define xdr_putbytes(xdrs, addr, len) \ - (*(xdrs)->x_ops->x_putbytes)(xdrs, addr, len) - -#define XDR_GETPOS(xdrs) \ - (*(xdrs)->x_ops->x_getpostn)(xdrs) -#define xdr_getpos(xdrs) \ - (*(xdrs)->x_ops->x_getpostn)(xdrs) - -#define XDR_SETPOS(xdrs, pos) \ - (*(xdrs)->x_ops->x_setpostn)(xdrs, pos) -#define xdr_setpos(xdrs, pos) \ - (*(xdrs)->x_ops->x_setpostn)(xdrs, pos) - -#define XDR_INLINE(xdrs, len) \ - (*(xdrs)->x_ops->x_inline)(xdrs, len) -#define xdr_inline(xdrs, len) \ - (*(xdrs)->x_ops->x_inline)(xdrs, len) - -#define XDR_DESTROY(xdrs) \ - do { \ - if ((xdrs)->x_ops->x_destroy) \ - (*(xdrs)->x_ops->x_destroy)(xdrs); \ - } while (0) -#define xdr_destroy(xdrs) \ - do { \ - if ((xdrs)->x_ops->x_destroy) \ - (*(xdrs)->x_ops->x_destroy)(xdrs); \ - } while (0) - -/* - * Support struct for discriminated unions. - * You create an array of xdrdiscrim structures, terminated with - * a entry with a null procedure pointer. The xdr_union routine gets - * the discriminant value and then searches the array of structures - * for a matching value. If a match is found the associated xdr routine - * is called to handle that part of the union. If there is - * no match, then a default routine may be called. - * If there is no match and no default routine it is an error. - */ -#define NULL_xdrproc_t ((xdrproc_t)0) -struct xdr_discrim -{ - int value; - xdrproc_t proc; -}; - -/* - * Inline routines for fast encode/decode of primitive data types. - * Caveat emptor: these use single memory cycles to get the - * data from the underlying buffer, and will fail to operate - * properly if the data is not aligned. The standard way to use these - * is to say: - * if ((buf = XDR_INLINE(xdrs, count)) == NULL) - * return (FALSE); - * <<< macro calls >>> - * where ``count'' is the number of bytes of data occupied - * by the primitive data types. - * - * N.B. and frozen for all time: each data type here uses 4 bytes - * of external representation. - */ - -#define IXDR_GET_INT32(buf) ((int32_t)ntohl((uint32_t)*(buf)++)) -#define IXDR_PUT_INT32(buf, v) (*(buf)++ = (int32_t)htonl((uint32_t)(v))) -#define IXDR_GET_U_INT32(buf) ((uint32_t)IXDR_GET_INT32(buf)) -#define IXDR_PUT_U_INT32(buf, v) IXDR_PUT_INT32(buf, (int32_t)(v)) - -/* WARNING: The IXDR_*_LONG defines are removed by Sun for new platforms - * and shouldn't be used any longer. Code which use this defines or longs - * in the RPC code will not work on 64bit Solaris platforms ! - */ -#define IXDR_GET_LONG(buf) \ - ((long)ntohl((u_long)*__extension__((u_int32_t*)(buf))++)) -#define IXDR_PUT_LONG(buf, v) \ - (*__extension__((u_int32_t*)(buf))++ = (long)htonl((u_long)(v))) -#define IXDR_GET_U_LONG(buf) ((u_long)IXDR_GET_LONG(buf)) -#define IXDR_PUT_U_LONG(buf, v) IXDR_PUT_LONG(buf, (long)(v)) - - -#define IXDR_GET_BOOL(buf) ((bool_t)IXDR_GET_LONG(buf)) -#define IXDR_GET_ENUM(buf, t) ((t)IXDR_GET_LONG(buf)) -#define IXDR_GET_SHORT(buf) ((short)IXDR_GET_LONG(buf)) -#define IXDR_GET_U_SHORT(buf) ((u_short)IXDR_GET_LONG(buf)) - -#define IXDR_PUT_BOOL(buf, v) IXDR_PUT_LONG(buf, (long)(v)) -#define IXDR_PUT_ENUM(buf, v) IXDR_PUT_LONG(buf, (long)(v)) -#define IXDR_PUT_SHORT(buf, v) IXDR_PUT_LONG(buf, (long)(v)) -#define IXDR_PUT_U_SHORT(buf, v) IXDR_PUT_LONG(buf, (long)(v)) - -/* - * These are the "generic" xdr routines. - * None of these can have const applied because it's not possible to - * know whether the call is a read or a write to the passed parameter - * also, the XDR structure is always updated by some of these calls. - */ -extern bool_t xdr_void (void) __THROW; -extern bool_t xdr_short (XDR *__xdrs, short *__sp) __THROW; -extern bool_t xdr_u_short (XDR *__xdrs, u_short *__usp) __THROW; -extern bool_t xdr_int (XDR *__xdrs, int *__ip) __THROW; -extern bool_t xdr_u_int (XDR *__xdrs, u_int *__up) __THROW; -extern bool_t xdr_long (XDR *__xdrs, long *__lp) __THROW; -extern bool_t xdr_u_long (XDR *__xdrs, u_long *__ulp) __THROW; -extern bool_t xdr_hyper (XDR *__xdrs, __quad_t *__llp) __THROW; -extern bool_t xdr_u_hyper (XDR *__xdrs, __u_quad_t *__ullp) __THROW; -extern bool_t xdr_longlong_t (XDR *__xdrs, __quad_t *__llp) __THROW; -extern bool_t xdr_u_longlong_t (XDR *__xdrs, __u_quad_t *__ullp) __THROW; -extern bool_t xdr_int8_t (XDR *__xdrs, int8_t *__ip) __THROW; -extern bool_t xdr_uint8_t (XDR *__xdrs, uint8_t *__up) __THROW; -extern bool_t xdr_int16_t (XDR *__xdrs, int16_t *__ip) __THROW; -extern bool_t xdr_uint16_t (XDR *__xdrs, uint16_t *__up) __THROW; -extern bool_t xdr_int32_t (XDR *__xdrs, int32_t *__ip) __THROW; -extern bool_t xdr_uint32_t (XDR *__xdrs, uint32_t *__up) __THROW; -extern bool_t xdr_int64_t (XDR *__xdrs, int64_t *__ip) __THROW; -extern bool_t xdr_uint64_t (XDR *__xdrs, uint64_t *__up) __THROW; -extern bool_t xdr_bool (XDR *__xdrs, bool_t *__bp) __THROW; -extern bool_t xdr_enum (XDR *__xdrs, enum_t *__ep) __THROW; -extern bool_t xdr_array (XDR * _xdrs, caddr_t *__addrp, u_int *__sizep, - u_int __maxsize, u_int __elsize, xdrproc_t __elproc) - __THROW; -extern bool_t xdr_bytes (XDR *__xdrs, char **__cpp, u_int *__sizep, - u_int __maxsize) __THROW; -extern bool_t xdr_opaque (XDR *__xdrs, caddr_t __cp, u_int __cnt) __THROW; -extern bool_t xdr_string (XDR *__xdrs, char **__cpp, u_int __maxsize) __THROW; -extern bool_t xdr_union (XDR *__xdrs, enum_t *__dscmp, char *__unp, - const struct xdr_discrim *__choices, - xdrproc_t dfault) __THROW; -extern bool_t xdr_char (XDR *__xdrs, char *__cp) __THROW; -extern bool_t xdr_u_char (XDR *__xdrs, u_char *__cp) __THROW; -extern bool_t xdr_vector (XDR *__xdrs, char *__basep, u_int __nelem, - u_int __elemsize, xdrproc_t __xdr_elem) __THROW; -extern bool_t xdr_float (XDR *__xdrs, float *__fp) __THROW; -extern bool_t xdr_double (XDR *__xdrs, double *__dp) __THROW; -extern bool_t xdr_reference (XDR *__xdrs, caddr_t *__xpp, u_int __size, - xdrproc_t __proc) __THROW; -extern bool_t xdr_pointer (XDR *__xdrs, char **__objpp, - u_int __obj_size, xdrproc_t __xdr_obj) __THROW; -extern bool_t xdr_wrapstring (XDR *__xdrs, char **__cpp) __THROW; -extern u_long xdr_sizeof (xdrproc_t, void *) __THROW; - -/* - * Common opaque bytes objects used by many rpc protocols; - * declared here due to commonality. - */ -#define MAX_NETOBJ_SZ 1024 -struct netobj -{ - u_int n_len; - char *n_bytes; -}; -typedef struct netobj netobj; -extern bool_t xdr_netobj (XDR *__xdrs, struct netobj *__np) __THROW; - -/* - * These are the public routines for the various implementations of - * xdr streams. - */ - -/* XDR using memory buffers */ -extern void xdrmem_create (XDR *__xdrs, const caddr_t __addr, - u_int __size, enum xdr_op __xop) __THROW; - -/* XDR using stdio library */ -extern void xdrstdio_create (XDR *__xdrs, FILE *__file, enum xdr_op __xop) - __THROW; - -/* XDR pseudo records for tcp */ -extern void xdrrec_create (XDR *__xdrs, u_int __sendsize, - u_int __recvsize, caddr_t __tcp_handle, - int (*__readit) (char *, char *, int), - int (*__writeit) (char *, char *, int)) __THROW; - -/* make end of xdr record */ -extern bool_t xdrrec_endofrecord (XDR *__xdrs, bool_t __sendnow) __THROW; - -/* move to beginning of next record */ -extern bool_t xdrrec_skiprecord (XDR *__xdrs) __THROW; - -/* true if no more input */ -extern bool_t xdrrec_eof (XDR *__xdrs) __THROW; - -/* free memory buffers for xdr */ -extern void xdr_free (xdrproc_t __proc, char *__objp) __THROW; - -__END_DECLS - -#endif /* rpc/xdr.h */ diff --git a/mdk-stage1/dietlibc/include/sched.h b/mdk-stage1/dietlibc/include/sched.h deleted file mode 100644 index 5e4430d29..000000000 --- a/mdk-stage1/dietlibc/include/sched.h +++ /dev/null @@ -1,74 +0,0 @@ -#ifndef _SCHED_H -#define _SCHED_H 1 - -#include - -#include -#ifndef u16 -#define u16 __u16 -#endif - -/* till those F**KIN' kernel headers are sane: A COPY ! - * #include - * A COPY OF THE STUFF WE NEED.... *GRUMBLE* */ - -/* - * cloning flags: - */ -#define CSIGNAL 0x000000ff /* signal mask to be sent at exit */ -#define CLONE_VM 0x00000100 /* set if VM shared between processes */ -#define CLONE_FS 0x00000200 /* set if fs info shared between processes */ -#define CLONE_FILES 0x00000400 /* set if open files shared between processes */ -#define CLONE_SIGHAND 0x00000800 /* set if signal handlers and blocked signals shared */ -#define CLONE_PID 0x00001000 /* set if pid shared */ -#define CLONE_PTRACE 0x00002000 /* set if we want to let tracing continue on the child too */ -#define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */ -#define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */ -#define CLONE_THREAD 0x00010000 /* Same thread group? */ - -#define CLONE_SIGNAL (CLONE_SIGHAND | CLONE_THREA) - -/* - * Scheduling policies - */ -#define SCHED_OTHER 0 -#define SCHED_FIFO 1 -#define SCHED_RR 2 - -/* - * This is an additional bit set when we want to - * yield the CPU for one re-schedule.. - */ -#define SCHED_YIELD 0x10 - -struct sched_param { - int sched_priority; -}; - -/* END OF COPY form kernel-header */ - -int __sched_setparam(pid_t pid, const struct sched_param *p); -int sched_setparam(pid_t pid, const struct sched_param *p); - -int __sched_getparam(pid_t pid, struct sched_param *p); -int sched_getparam(pid_t pid, struct sched_param *p); - -int __sched_getscheduler(pid_t pid); -int sched_getscheduler(pid_t pid); - -int __sched_setscheduler(pid_t pid, int policy, const struct sched_param *p); -int sched_setscheduler(pid_t pid, int policy, const struct sched_param *p); - -int __sched_yield(void); -int sched_yield(void); - -int __sched_get_priority_max(int policy); -int sched_get_priority_max(int policy); - -int __sched_get_priority_min(int policy); -int sched_get_priority_min(int policy); - -int __sched_rr_get_interval(pid_t pid, struct timespec *tp); -int sched_rr_get_interval(pid_t pid, struct timespec *tp); - -#endif diff --git a/mdk-stage1/dietlibc/include/scsi/scsi.h b/mdk-stage1/dietlibc/include/scsi/scsi.h deleted file mode 100644 index 652e44ee9..000000000 --- a/mdk-stage1/dietlibc/include/scsi/scsi.h +++ /dev/null @@ -1,224 +0,0 @@ -/* Copyright (C) 1998, 1999 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with the GNU C Library; see the file COPYING.LIB. If not, - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -/* - * This header file contains public constants and structures used by - * the scsi code for linux. - */ - -#ifndef _SCSI_SCSI_H -#define _SCSI_SCSI_H 1 - -/* - * SCSI opcodes - */ - -#define TEST_UNIT_READY 0x00 -#define REZERO_UNIT 0x01 -#define REQUEST_SENSE 0x03 -#define FORMAT_UNIT 0x04 -#define READ_BLOCK_LIMITS 0x05 -#define REASSIGN_BLOCKS 0x07 -#define READ_6 0x08 -#define WRITE_6 0x0a -#define SEEK_6 0x0b -#define READ_REVERSE 0x0f -#define WRITE_FILEMARKS 0x10 -#define SPACE 0x11 -#define INQUIRY 0x12 -#define RECOVER_BUFFERED_DATA 0x14 -#define MODE_SELECT 0x15 -#define RESERVE 0x16 -#define RELEASE 0x17 -#define COPY 0x18 -#define ERASE 0x19 -#define MODE_SENSE 0x1a -#define START_STOP 0x1b -#define RECEIVE_DIAGNOSTIC 0x1c -#define SEND_DIAGNOSTIC 0x1d -#define ALLOW_MEDIUM_REMOVAL 0x1e - -#define SET_WINDOW 0x24 -#define READ_CAPACITY 0x25 -#define READ_10 0x28 -#define WRITE_10 0x2a -#define SEEK_10 0x2b -#define WRITE_VERIFY 0x2e -#define VERIFY 0x2f -#define SEARCH_HIGH 0x30 -#define SEARCH_EQUAL 0x31 -#define SEARCH_LOW 0x32 -#define SET_LIMITS 0x33 -#define PRE_FETCH 0x34 -#define READ_POSITION 0x34 -#define SYNCHRONIZE_CACHE 0x35 -#define LOCK_UNLOCK_CACHE 0x36 -#define READ_DEFECT_DATA 0x37 -#define MEDIUM_SCAN 0x38 -#define COMPARE 0x39 -#define COPY_VERIFY 0x3a -#define WRITE_BUFFER 0x3b -#define READ_BUFFER 0x3c -#define UPDATE_BLOCK 0x3d -#define READ_LONG 0x3e -#define WRITE_LONG 0x3f -#define CHANGE_DEFINITION 0x40 -#define WRITE_SAME 0x41 -#define READ_TOC 0x43 -#define LOG_SELECT 0x4c -#define LOG_SENSE 0x4d -#define MODE_SELECT_10 0x55 -#define RESERVE_10 0x56 -#define RELEASE_10 0x57 -#define MODE_SENSE_10 0x5a -#define PERSISTENT_RESERVE_IN 0x5e -#define PERSISTENT_RESERVE_OUT 0x5f -#define MOVE_MEDIUM 0xa5 -#define READ_12 0xa8 -#define WRITE_12 0xaa -#define WRITE_VERIFY_12 0xae -#define SEARCH_HIGH_12 0xb0 -#define SEARCH_EQUAL_12 0xb1 -#define SEARCH_LOW_12 0xb2 -#define READ_ELEMENT_STATUS 0xb8 -#define SEND_VOLUME_TAG 0xb6 -#define WRITE_LONG_2 0xea - -/* - * Status codes - */ - -#define GOOD 0x00 -#define CHECK_CONDITION 0x01 -#define CONDITION_GOOD 0x02 -#define BUSY 0x04 -#define INTERMEDIATE_GOOD 0x08 -#define INTERMEDIATE_C_GOOD 0x0a -#define RESERVATION_CONFLICT 0x0c -#define COMMAND_TERMINATED 0x11 -#define QUEUE_FULL 0x14 - -#define STATUS_MASK 0x3e - -/* - * SENSE KEYS - */ - -#define NO_SENSE 0x00 -#define RECOVERED_ERROR 0x01 -#define NOT_READY 0x02 -#define MEDIUM_ERROR 0x03 -#define HARDWARE_ERROR 0x04 -#define ILLEGAL_REQUEST 0x05 -#define UNIT_ATTENTION 0x06 -#define DATA_PROTECT 0x07 -#define BLANK_CHECK 0x08 -#define COPY_ABORTED 0x0a -#define ABORTED_COMMAND 0x0b -#define VOLUME_OVERFLOW 0x0d -#define MISCOMPARE 0x0e - - -/* - * DEVICE TYPES - */ - -#define TYPE_DISK 0x00 -#define TYPE_TAPE 0x01 -#define TYPE_PROCESSOR 0x03 /* HP scanners use this */ -#define TYPE_WORM 0x04 /* Treated as ROM by our system */ -#define TYPE_ROM 0x05 -#define TYPE_SCANNER 0x06 -#define TYPE_MOD 0x07 /* Magneto-optical disk - - * - treated as TYPE_DISK */ -#define TYPE_MEDIUM_CHANGER 0x08 -#define TYPE_ENCLOSURE 0x0d /* Enclosure Services Device */ -#define TYPE_NO_LUN 0x7f - -/* - * standard mode-select header prepended to all mode-select commands - * - * moved here from cdrom.h -- kraxel - */ - -struct ccs_modesel_head - { - unsigned char _r1; /* reserved. */ - unsigned char medium; /* device-specific medium type. */ - unsigned char _r2; /* reserved. */ - unsigned char block_desc_length; /* block descriptor length. */ - unsigned char density; /* device-specific density code. */ - unsigned char number_blocks_hi; /* number of blocks in this block - desc. */ - unsigned char number_blocks_med; - unsigned char number_blocks_lo; - unsigned char _r3; - unsigned char block_length_hi; /* block length for blocks in this - desc. */ - unsigned char block_length_med; - unsigned char block_length_lo; - }; - -/* - * MESSAGE CODES - */ - -#define COMMAND_COMPLETE 0x00 -#define EXTENDED_MESSAGE 0x01 -#define EXTENDED_MODIFY_DATA_POINTER 0x00 -#define EXTENDED_SDTR 0x01 -#define EXTENDED_EXTENDED_IDENTIFY 0x02 /* SCSI-I only */ -#define EXTENDED_WDTR 0x03 -#define SAVE_POINTERS 0x02 -#define RESTORE_POINTERS 0x03 -#define DISCONNECT 0x04 -#define INITIATOR_ERROR 0x05 -#define ABORT 0x06 -#define MESSAGE_REJECT 0x07 -#define NOP 0x08 -#define MSG_PARITY_ERROR 0x09 -#define LINKED_CMD_COMPLETE 0x0a -#define LINKED_FLG_CMD_COMPLETE 0x0b -#define BUS_DEVICE_RESET 0x0c - -#define INITIATE_RECOVERY 0x0f /* SCSI-II only */ -#define RELEASE_RECOVERY 0x10 /* SCSI-II only */ - -#define SIMPLE_QUEUE_TAG 0x20 -#define HEAD_OF_QUEUE_TAG 0x21 -#define ORDERED_QUEUE_TAG 0x22 - -/* - * Here are some scsi specific ioctl commands which are sometimes useful. - */ -/* These are a few other constants only used by scsi devices. */ - -#define SCSI_IOCTL_GET_IDLUN 0x5382 - -/* Used to turn on and off tagged queuing for scsi devices. */ - -#define SCSI_IOCTL_TAGGED_ENABLE 0x5383 -#define SCSI_IOCTL_TAGGED_DISABLE 0x5384 - -/* Used to obtain the host number of a device. */ -#define SCSI_IOCTL_PROBE_HOST 0x5385 - -/* Used to get the bus number for a device. */ -#define SCSI_IOCTL_GET_BUS_NUMBER 0x5386 - -#endif /* scsi/scsi.h */ diff --git a/mdk-stage1/dietlibc/include/scsi/scsi_ioctl.h b/mdk-stage1/dietlibc/include/scsi/scsi_ioctl.h deleted file mode 100644 index bc9931838..000000000 --- a/mdk-stage1/dietlibc/include/scsi/scsi_ioctl.h +++ /dev/null @@ -1,34 +0,0 @@ -/* Copyright (C) 1999 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with the GNU C Library; see the file COPYING.LIB. If not, - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -#ifndef _SCSI_IOCTL_H -#define _SCSI_IOCTL_H - -/* IOCTLs for SCSI. */ -#define SCSI_IOCTL_SEND_COMMAND 1 /* Send a command to the SCSI host. */ -#define SCSI_IOCTL_TEST_UNIT_READY 2 /* Test if unit is ready. */ -#define SCSI_IOCTL_BENCHMARK_COMMAND 3 -#define SCSI_IOCTL_SYNC 4 /* Request synchronous parameters. */ -#define SCSI_IOCTL_START_UNIT 5 -#define SCSI_IOCTL_STOP_UNIT 6 -#define SCSI_IOCTL_DOORLOCK 0x5380 /* Lock the eject mechanism. */ -#define SCSI_IOCTL_DOORUNLOCK 0x5381 /* Unlock the mechanism. */ - -#endif - - diff --git a/mdk-stage1/dietlibc/include/scsi/sg.h b/mdk-stage1/dietlibc/include/scsi/sg.h deleted file mode 100644 index 00334654e..000000000 --- a/mdk-stage1/dietlibc/include/scsi/sg.h +++ /dev/null @@ -1,274 +0,0 @@ -/* Copyright (C) 1997, 1998, 1999, 2000 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with the GNU C Library; see the file COPYING.LIB. If not, - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -/* - History: - Started: Aug 9 by Lawrence Foard (entropy@world.std.com), to allow user - process control of SCSI devices. - Development Sponsored by Killy Corp. NY NY -*/ - -#ifndef _SCSI_SG_H -#define _SCSI_SG_H 1 - -#include - -/* New interface introduced in the 3.x SG drivers follows */ - -/* Same structure as used by readv() Linux system call. It defines one - scatter-gather element. */ -typedef struct sg_iovec -{ - void * iov_base; /* Starting address */ - size_t iov_len; /* Length in bytes */ -} sg_iovec_t; - - -typedef struct sg_io_hdr -{ - int interface_id; /* [i] 'S' for SCSI generic (required) */ - int dxfer_direction; /* [i] data transfer direction */ - unsigned char cmd_len; /* [i] SCSI command length ( <= 16 bytes) */ - unsigned char mx_sb_len; /* [i] max length to write to sbp */ - unsigned short int iovec_count; /* [i] 0 implies no scatter gather */ - unsigned int dxfer_len; /* [i] byte count of data transfer */ - void * dxferp; /* [i], [*io] points to data transfer memory - or scatter gather list */ - unsigned char * cmdp; /* [i], [*i] points to command to perform */ - unsigned char * sbp; /* [i], [*o] points to sense_buffer memory */ - unsigned int timeout; /* [i] MAX_UINT->no timeout (unit: millisec) */ - unsigned int flags; /* [i] 0 -> default, see SG_FLAG... */ - int pack_id; /* [i->o] unused internally (normally) */ - void * usr_ptr; /* [i->o] unused internally */ - unsigned char status; /* [o] scsi status */ - unsigned char masked_status;/* [o] shifted, masked scsi status */ - unsigned char msg_status; /* [o] messaging level data (optional) */ - unsigned char sb_len_wr; /* [o] byte count actually written to sbp */ - unsigned short int host_status; /* [o] errors from host adapter */ - unsigned short int driver_status;/* [o] errors from software driver */ - int resid; /* [o] dxfer_len - actual_transferred */ - unsigned int duration; /* [o] time taken by cmd (unit: millisec) */ - unsigned int info; /* [o] auxiliary information */ -} sg_io_hdr_t; - - -/* Use negative values to flag difference from original sg_header structure. */ -#define SG_DXFER_NONE -1 /* e.g. a SCSI Test Unit Ready command */ -#define SG_DXFER_TO_DEV -2 /* e.g. a SCSI WRITE command */ -#define SG_DXFER_FROM_DEV -3 /* e.g. a SCSI READ command */ -#define SG_DXFER_TO_FROM_DEV -4 /* treated like SG_DXFER_FROM_DEV with the - additional property than during indirect - IO the user buffer is copied into the - kernel buffers before the transfer */ - - -/* following flag values can be "or"-ed together */ -#define SG_FLAG_DIRECT_IO 1 /* default is indirect IO */ -#define SG_FLAG_LUN_INHIBIT 2 /* default is to put device's lun into */ - /* the 2nd byte of SCSI command */ -#define SG_FLAG_NO_DXFER 0x10000 /* no transfer of kernel buffers to/from */ - /* user space (debug indirect IO) */ - -/* The following 'info' values are "or"-ed together. */ -#define SG_INFO_OK_MASK 0x1 -#define SG_INFO_OK 0x0 /* no sense, host nor driver "noise" */ -#define SG_INFO_CHECK 0x1 /* something abnormal happened */ - -#define SG_INFO_DIRECT_IO_MASK 0x6 -#define SG_INFO_INDIRECT_IO 0x0 /* data xfer via kernel buffers (or no xfer) */ -#define SG_INFO_DIRECT_IO 0x2 /* direct IO requested and performed */ -#define SG_INFO_MIXED_IO 0x4 /* part direct, part indirect IO */ - - -/* Request information about a specific SG device, used by - SG_GET_SCSI_ID ioctl (). */ -struct sg_scsi_id { - /* Host number as in "scsi" where 'n' is one of 0, 1, 2 etc. */ - int host_no; - int channel; - /* SCSI id of target device. */ - int scsi_id; - int lun; - /* TYPE_... defined in . */ - int scsi_type; - /* Host (adapter) maximum commands per lun. */ - short int h_cmd_per_lun; - /* Device (or adapter) maximum queue length. */ - short int d_queue_depth; - /* Unused, set to 0 for now. */ - int unused[2]; -}; - -/* Used by SG_GET_REQUEST_TABLE ioctl(). */ -typedef struct sg_req_info { - char req_state; /* 0 -> not used, 1 -> written, 2 -> ready to read */ - char orphan; /* 0 -> normal request, 1 -> from interruped SG_IO */ - char sg_io_owned; /* 0 -> complete with read(), 1 -> owned by SG_IO */ - char problem; /* 0 -> no problem detected, 1 -> error to report */ - int pack_id; /* pack_id associated with request */ - void * usr_ptr; /* user provided pointer (in new interface) */ - unsigned int duration; /* millisecs elapsed since written (req_state==1) - or request duration (req_state==2) */ - int unused; -} sg_req_info_t; - - -/* IOCTLs: Those ioctls that are relevant to the SG 3.x drivers follow. - [Those that only apply to the SG 2.x drivers are at the end of the file.] - (_GET_s yield result via 'int *' 3rd argument unless otherwise indicated) */ - -#define SG_EMULATED_HOST 0x2203 /* true for emulated host adapter (ATAPI) */ - -/* Used to configure SCSI command transformation layer for ATAPI devices */ -/* Only supported by the ide-scsi driver */ -#define SG_SET_TRANSFORM 0x2204 /* N.B. 3rd arg is not pointer but value: */ - /* 3rd arg = 0 to disable transform, 1 to enable it */ -#define SG_GET_TRANSFORM 0x2205 - -#define SG_SET_RESERVED_SIZE 0x2275 /* request a new reserved buffer size */ -#define SG_GET_RESERVED_SIZE 0x2272 /* actual size of reserved buffer */ - -/* The following ioctl has a 'sg_scsi_id_t *' object as its 3rd argument. */ -#define SG_GET_SCSI_ID 0x2276 /* Yields fd's bus, chan, dev, lun + type */ -/* SCSI id information can also be obtained from SCSI_IOCTL_GET_IDLUN */ - -/* Override host setting and always DMA using low memory ( <16MB on i386) */ -#define SG_SET_FORCE_LOW_DMA 0x2279 /* 0-> use adapter setting, 1-> force */ -#define SG_GET_LOW_DMA 0x227a /* 0-> use all ram for dma; 1-> low dma ram */ - -/* When SG_SET_FORCE_PACK_ID set to 1, pack_id is input to read() which - tries to fetch a packet with a matching pack_id, waits, or returns EAGAIN. - If pack_id is -1 then read oldest waiting. When ...FORCE_PACK_ID set to 0 - then pack_id ignored by read() and oldest readable fetched. */ -#define SG_SET_FORCE_PACK_ID 0x227b -#define SG_GET_PACK_ID 0x227c /* Yields oldest readable pack_id (or -1) */ - -#define SG_GET_NUM_WAITING 0x227d /* Number of commands awaiting read() */ - -/* Yields max scatter gather tablesize allowed by current host adapter */ -#define SG_GET_SG_TABLESIZE 0x227F /* 0 implies can't do scatter gather */ - -#define SG_GET_VERSION_NUM 0x2282 /* Example: version 2.1.34 yields 20134 */ - -/* Returns -EBUSY if occupied. 3rd argument pointer to int (see next) */ -#define SG_SCSI_RESET 0x2284 -/* Associated values that can be given to SG_SCSI_RESET follow */ -#define SG_SCSI_RESET_NOTHING 0 -#define SG_SCSI_RESET_DEVICE 1 -#define SG_SCSI_RESET_BUS 2 -#define SG_SCSI_RESET_HOST 3 - -/* synchronous SCSI command ioctl, (only in version 3 interface) */ -#define SG_IO 0x2285 /* similar effect as write() followed by read() */ - -#define SG_GET_REQUEST_TABLE 0x2286 /* yields table of active requests */ - -/* How to treat EINTR during SG_IO ioctl(), only in SG 3.x series */ -#define SG_SET_KEEP_ORPHAN 0x2287 /* 1 -> hold for read(), 0 -> drop (def) */ -#define SG_GET_KEEP_ORPHAN 0x2288 - - -#define SG_SCATTER_SZ (8 * 4096) /* PAGE_SIZE not available to user */ -/* Largest size (in bytes) a single scatter-gather list element can have. - The value must be a power of 2 and <= (PAGE_SIZE * 32) [131072 bytes on - i386]. The minimum value is PAGE_SIZE. If scatter-gather not supported - by adapter then this value is the largest data block that can be - read/written by a single scsi command. The user can find the value of - PAGE_SIZE by calling getpagesize() defined in unistd.h . */ - -#define SG_DEFAULT_RETRIES 1 - -/* Defaults, commented if they differ from original sg driver */ -#define SG_DEF_FORCE_LOW_DMA 0 /* was 1 -> memory below 16MB on i386 */ -#define SG_DEF_FORCE_PACK_ID 0 -#define SG_DEF_KEEP_ORPHAN 0 -#define SG_DEF_RESERVED_SIZE SG_SCATTER_SZ /* load time option */ - -/* maximum outstanding requests, write() yields EDOM if exceeded */ -#define SG_MAX_QUEUE 16 - -#define SG_BIG_BUFF SG_DEF_RESERVED_SIZE /* for backward compatibility */ - -/* Alternate style type names, "..._t" variants preferred */ -typedef struct sg_io_hdr Sg_io_hdr; -typedef struct sg_io_vec Sg_io_vec; -typedef struct sg_scsi_id Sg_scsi_id; -typedef struct sg_req_info Sg_req_info; - - -/* vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv */ -/* The older SG interface based on the 'sg_header' structure follows. */ -/* ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ */ - -#define SG_MAX_SENSE 16 /* this only applies to the sg_header interface */ - -struct sg_header - { - /* Length of incoming packet (including header). */ - int pack_len; - /* Maximal length of expected reply. */ - int reply_len; - /* Id number of packet. */ - int pack_id; - /* 0==ok, otherwise error number. */ - int result; - /* Force 12 byte command length for group 6 & 7 commands. */ - unsigned int twelve_byte:1; - /* SCSI status from target. */ - unsigned int target_status:5; - /* Host status (see "DID" codes). */ - unsigned int host_status:8; - /* Driver status+suggestion. */ - unsigned int driver_status:8; - /* Unused. */ - unsigned int other_flags:10; - /* Output in 3 cases: - when target_status is CHECK_CONDITION or - when target_status is COMMAND_TERMINATED or - when (driver_status & DRIVER_SENSE) is true. */ - unsigned char sense_buffer[SG_MAX_SENSE]; - }; - - -/* IOCTLs: The following are not required (or ignored) when the sg_io_hdr_t - interface is used. They are kept for backward compatibility with - the original and version 2 drivers. */ - -#define SG_SET_TIMEOUT 0x2201 /* Set timeout; *(int *)arg==timeout. */ -#define SG_GET_TIMEOUT 0x2202 /* Get timeout; return timeout. */ - -/* Get/set command queuing state per fd (default is SG_DEF_COMMAND_Q). */ -#define SG_GET_COMMAND_Q 0x2270 /* Yields 0 (queuing off) or 1 (on). */ -#define SG_SET_COMMAND_Q 0x2271 /* Change queuing state with 0 or 1. */ - -/* Turn on error sense trace (1..8), dump this device to log/console (9) - or dump all sg device states ( >9 ) to log/console. */ -#define SG_SET_DEBUG 0x227e /* 0 -> turn off debug */ - -#define SG_NEXT_CMD_LEN 0x2283 /* Override SCSI command length with given - number on the next write() on this file - descriptor. */ - -/* Defaults, commented if they differ from original sg driver */ -#define SG_DEFAULT_TIMEOUT (60*HZ) /* HZ == 'jiffies in 1 second' */ -#define SG_DEF_COMMAND_Q 0 /* command queuing is always on when - the new interface is used */ -#define SG_DEF_UNDERRUN_FLAG 0 - - -#endif /* scsi/sg.h */ diff --git a/mdk-stage1/dietlibc/include/setjmp.h b/mdk-stage1/dietlibc/include/setjmp.h deleted file mode 100644 index 66fc288f4..000000000 --- a/mdk-stage1/dietlibc/include/setjmp.h +++ /dev/null @@ -1,123 +0,0 @@ -#ifndef _SETJMP_H -#define _SETJMP_H - -#include - -#ifdef __i386__ -#ifndef __ASSEMBLER__ -typedef int __jmp_buf[6]; -#endif -# define JB_BX 0 -# define JB_SI 1 -# define JB_DI 2 -# define JB_BP 3 -# define JB_SP 4 -# define JB_PC 5 -# define JB_SIZE 24 -#endif - -#ifdef __alpha__ -#define JB_S0 0 -#define JB_S1 1 -#define JB_S2 2 -#define JB_S3 3 -#define JB_S4 4 -#define JB_S5 5 -#define JB_PC 6 -#define JB_FP 7 -#define JB_SP 8 -#define JB_F2 9 -#define JB_F3 10 -#define JB_F4 11 -#define JB_F5 12 -#define JB_F6 13 -#define JB_F7 14 -#define JB_F8 15 -#define JB_F9 16 -#ifndef __ASSEMBLER__ -typedef long int __jmp_buf[17]; -#endif -#endif - -#ifdef __mips__ -#ifndef __ASSEMBLER__ -typedef struct - { - void * __pc; /* Program counter. */ - void * __sp; /* Stack pointer. */ - int __regs[8]; /* Callee-saved registers s0 through s7. */ - void * __fp; /* The frame pointer. */ - void * __gp; /* The global pointer. */ - int __fpc_csr; /* Floating point status register. */ - double __fpregs[6]; /* Callee-saved floating point registers. */ - } __jmp_buf[1]; -#endif -#endif - -#ifdef __sparc__ -#define JB_SP 0 -#define JB_FP 1 -#define JB_PC 2 -#ifndef __ASSEMBLER__ -typedef int __jmp_buf[3]; -#endif -#endif - -#ifdef __arm__ -#define __JMP_BUF_SP 8 -#ifndef __ASSEMBLER__ -typedef int __jmp_buf[10]; -#endif -#endif - -#ifdef __powerpc__ -# define JB_GPR1 0 /* Also known as the stack pointer */ -# define JB_GPR2 1 -# define JB_LR 2 /* The address we will return to */ -# define JB_GPRS 3 /* GPRs 14 through 31 are saved, 18 in total */ -# define JB_CR 21 /* Condition code registers. */ -# define JB_FPRS 22 /* FPRs 14 through 31 are saved, 18*2 words total */ -# define JB_SIZE (58*4) -#ifndef __ASSEMBLER__ -typedef long int __jmp_buf[58]; -#endif -#endif - -#ifndef __ASSEMBLER__ - -typedef int sig_atomic_t; -#define __sig_atomic_t sig_atomic_t - -# define _SIGSET_NWORDS (1024 / (8 * sizeof (unsigned long int))) -typedef struct - { - unsigned long int __val[_SIGSET_NWORDS]; - } __sigset_t; - -/* Calling environment, plus possibly a saved signal mask. */ -typedef struct __jmp_buf_tag /* C++ doesn't like tagless structs. */ - { - /* NOTE: The machine-dependent definitions of `__sigsetjmp' - assume that a `jmp_buf' begins with a `__jmp_buf'. - Do not move this member or add others before it. */ - __jmp_buf __jmpbuf; /* Calling environment. */ - int __mask_was_saved; /* Saved the signal mask? */ - __sigset_t __saved_mask; /* Saved signal mask. */ - } jmp_buf[1]; - -extern int __sigsetjmp (jmp_buf __env, int __savemask) __THROW; - -extern void longjmp (jmp_buf __env, int __val) - __THROW __attribute__ ((__noreturn__)); - -typedef jmp_buf sigjmp_buf; - -extern void siglongjmp (sigjmp_buf __env, int __val) - __THROW __attribute__ ((__noreturn__)); - -#define setjmp(env) __sigsetjmp(env,0) -#define sigsetjmp(a,b) __sigsetjmp(a,b) - -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/shadow.h b/mdk-stage1/dietlibc/include/shadow.h deleted file mode 100644 index 4d6341af1..000000000 --- a/mdk-stage1/dietlibc/include/shadow.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef _SHADOW_H -#define _SHADOW_H - -#include -#include - -struct spwd { - char *sp_namp; /* user login name */ - char *sp_pwdp; /* encrypted password */ - long sp_lstchg; /* last password change */ - int sp_min; /* days until change allowed. */ - int sp_max; /* days before change required */ - int sp_warn; /* days warning for expiration */ - int sp_inact; /* days before account inactive */ - int sp_expire; /* date when account expires */ - int sp_flag; /* reserved for future use */ -}; - -extern struct spwd *getspent(void) __THROW; -extern void setspent(void) __THROW; -extern void endspent(void) __THROW; -extern struct spwd *getspnam (__const char *__name) __THROW; - -#endif /* _SHADOW_H */ diff --git a/mdk-stage1/dietlibc/include/signal.h b/mdk-stage1/dietlibc/include/signal.h deleted file mode 100644 index 9ed93fe83..000000000 --- a/mdk-stage1/dietlibc/include/signal.h +++ /dev/null @@ -1,35 +0,0 @@ -#ifndef _SIGNAL_H -#define _SIGNAL_H - -#include - -#define __WANT_POSIX1B_SIGNALS__ - -#include -#include - -typedef void (*sighandler_t)(int); - -int sigemptyset(sigset_t *set) __THROW; -int sigfillset(sigset_t *set) __THROW; -int sigaddset(sigset_t *set, int signum) __THROW; -int sigdelset(sigset_t *set, int signum) __THROW; -int sigprocmask(int how, const sigset_t *set, sigset_t *oldset) __THROW; -sighandler_t signal(int signum, sighandler_t action); -int raise (int sig) __THROW; -int sigaction(int signum, const struct sigaction *act, struct sigaction *oldact) __THROW; -int sigaltstack(const struct sigaltstack *newstack, struct sigaltstack *oldstack) __THROW; - -#ifndef SIGCLD -#define SIGCLD SIGCHLD -#endif - -extern const char *const sys_siglist[]; - -typedef __sighandler_t sig_t; - -#ifndef NSIG -#define NSIG _NSIG -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/stdint.h b/mdk-stage1/dietlibc/include/stdint.h deleted file mode 100644 index d287e6794..000000000 --- a/mdk-stage1/dietlibc/include/stdint.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _STDINT_H -#define _STDINT_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/stdio.h b/mdk-stage1/dietlibc/include/stdio.h deleted file mode 100644 index 92d9dc0cb..000000000 --- a/mdk-stage1/dietlibc/include/stdio.h +++ /dev/null @@ -1,97 +0,0 @@ -#ifndef _STDIO_H -#define _STDIO_H - -#include -#include - -typedef struct __stdio_file FILE; - -FILE *fopen (const char *path, const char *mode) __THROW; -FILE *fdopen (int fildes, const char *mode) __THROW; -FILE *freopen (const char *path, const char *mode, FILE *stream) __THROW; - -int printf(const char *format, ...) __THROW; -int fprintf(FILE *stream, const char *format, ...) __THROW; -int sprintf(char *str, const char *format, ...) __THROW; -int snprintf(char *str, size_t size, const char *format, ...) __THROW; -int asprintf(char **ptr, const char* format, ...) __THROW; - -int scanf( const char *format, ...) __THROW; -int fscanf( FILE *stream, const char *format, ...) __THROW; -int sscanf( const char *str, const char *format, ...) __THROW; - -#include - -int vprintf(const char *format, va_list ap) __THROW; -int vfprintf(FILE *stream, const char *format, va_list ap) __THROW; -int vsprintf(char *str, const char *format, va_list ap) __THROW; -int vsnprintf(char *str, size_t size, const char *format, va_list ap) __THROW; - -int vscanf( const char *format, va_list ap) __THROW; -int vsscanf( const char *str, const char *format, va_list ap) __THROW; -int vfscanf( FILE *stream, const char *format, va_list ap) __THROW; - -int fgetc(FILE *stream) __THROW; -char *fgets(char *s, int size, FILE *stream) __THROW; -int getc(FILE *stream) __THROW; -int getchar(void) __THROW; -char *gets(char *s) __THROW; -int ungetc(int c, FILE *stream) __THROW; - -int fputc(int c, FILE *stream) __THROW; -int fputs(const char *s, FILE *stream) __THROW; - -#define putc(c,stream) fputc(c,stream) -#define putchar(c) fputc(c,stdout) - -#define getchar() fgetc(stdin) -#define getc(stream) fgetc(stream) - -int puts(const char *s) __THROW; - -long fseek( FILE *stream, long offset, int whence) __THROW; -long ftell( FILE *stream) __THROW; -void rewind( FILE *stream) __THROW; -int fgetpos( FILE *stream, fpos_t *pos) __THROW; -int fsetpos( FILE *stream, fpos_t *pos) __THROW; - -size_t fread( void *ptr, size_t size, size_t nmemb, FILE *stream) __THROW; - -size_t fwrite( const void *ptr, size_t size, size_t nmemb, FILE *stream) __THROW; - -int fflush(FILE *stream) __THROW; - -int fclose(FILE *stream) __THROW; - -void clearerr(FILE *stream) __THROW; -int feof (FILE *stream) __THROW; -int ferror( FILE *stream) __THROW; -int fileno( FILE *stream) __THROW; - -int remove(const char *pathname) __THROW; - -void perror(const char *s) __THROW; - -extern FILE *stdin, *stdout, *stderr; - -#define EOF (int)(-1) - -#define BUFSIZ 128 - -#define _IONBF 0 -#define _IOLBF 1 -#define _IOFBF 2 - -int setvbuf(FILE *stream, char *buf, int mode , size_t size) __THROW; - -#define setbuf(stream,buf) setvbuf(stream,buf,buf?_IOFBF:_IONBF,BUFSIZ) -#define setbuffer(stream,buf,size) setvbuf(stream,buf,buf?_IOFBF:_IONBF,size) -#define setlinebuf(stream) setvbuf(stream,0,_IOLBF,BUFSIZ) - -FILE *popen(const char *command, const char *type) __THROW; -int pclose(FILE *stream) __THROW; - -#define getc_unlocked(stream) getc(stream) -#define putc_unlocked(c,stream) putc(c,stream) - -#endif diff --git a/mdk-stage1/dietlibc/include/stdlib.h b/mdk-stage1/dietlibc/include/stdlib.h deleted file mode 100644 index 6a13a48ff..000000000 --- a/mdk-stage1/dietlibc/include/stdlib.h +++ /dev/null @@ -1,67 +0,0 @@ -#ifndef _STDLIB_H -#define _STDLIB_H - -#include -#include - -#define __LIBC_DIETLIBC__ - -void *calloc(size_t nmemb, size_t size) __THROW; -void *malloc(size_t size) __THROW; -void free(void *ptr) __THROW; -void *realloc(void *ptr, size_t size) __THROW; - -char *getenv(const char *name) __THROW __pure__; -int putenv(const char *string) __THROW; -int setenv(const char *name, const char *value, int overwrite) __THROW; -void unsetenv(const char *name) __THROW; - -int atexit(void (*function)(void)) __THROW; - -double strtod(const char *nptr, char **endptr) __THROW; -long int strtol(const char *nptr, char **endptr, int base) __THROW; -unsigned long int strtoul(const char *nptr, char **endptr, int base) __THROW; - -int __ltostr(char *s, int size, unsigned long i, int base, char UpCase) __THROW; -#ifdef __GNUC__ -long long int strtoll(const char *nptr, char **endptr, int base) __THROW; -unsigned long long int strtoull(const char *nptr, char **endptr, int base) __THROW; -int __lltostr(char *s, int size, unsigned long long i, int base, char UpCase) __THROW; -#endif - -int atoi(const char *nptr) __THROW; -long int atol(const char *nptr) __THROW; -double atof(const char *nptr) __THROW; - -void exit(int status) __THROW __attribute__((noreturn)); -void abort(void) __THROW; - -/* warning: the rand() implementation of the diet libc really sucks. */ -#define RAND_MAX 32767 - -extern int rand(void) __THROW; -extern void srand(unsigned int seed) __THROW; - -void qsort(void *base, size_t nmemb, size_t size, int (*compar)(const void *, const void *)) __THROW; -void *bsearch(const void *key, const void *base, size_t nmemb, size_t size, int (*compar)(const void *, const void *)) __THROW; - -extern char **environ; - -#define EXIT_SUCCESS 0 -#define EXIT_FAILURE 1 - -/* now this function is the greatest bullshit I have ever seen. - * The ISO people must be out of their minds. */ -typedef struct { int quot,rem; } div_t; -div_t div(int numer, int denom) __THROW __attribute__((const)); - -void *alloca(size_t size) __THROW; /* gcc built-in */ - -char *realpath(const char *path, char *resolved_path) __THROW; - -int abs(int j) __THROW; - -long int random(void) __THROW; -void srandom(unsigned int seed) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/string.h b/mdk-stage1/dietlibc/include/string.h deleted file mode 100644 index 1ef78ae54..000000000 --- a/mdk-stage1/dietlibc/include/string.h +++ /dev/null @@ -1,57 +0,0 @@ -#ifndef _STRING_H -#define _STRING_H - -#include -#include - -char *strcpy(char *dest, const char *src) __THROW; -char *strncpy(char *dest, const char *src, size_t n) __THROW; - -void *memccpy(void *dest, const void *src, int c, size_t n) __THROW; -void *memcpy(void *dest, const void *src, size_t n) __THROW; -void *memmove(void *dest, const void *src, size_t n) __THROW; - -int memccmp(const void *s1, const void *s2, int c, size_t n) __THROW __pure__; -int memcmp(const void *s1, const void *s2, size_t n) __THROW __pure__; -int strcmp(const char *s1, const char *s2) __THROW __pure__; -int strncmp(const char *s1, const char *s2, size_t n) __THROW __pure__; - -int strcasecmp(const char *s1, const char *s2) __THROW __pure__; -int strncasecmp(const char *s1, const char *s2, size_t n) __THROW __pure__; - -size_t strlen(const char *s) __THROW __pure__; - -char *strstr(const char *haystack, const char *needle) __THROW __pure__; - -char *strdup(const char *s) __THROW; - -char *strchr(const char *s, int c) __THROW __pure__; -char *strrchr(const char *s, int c) __THROW __pure__; - -char *strcat(char *dest, const char *src) __THROW; -char *strncat(char *dest, const char *src, size_t n) __THROW; - -size_t strspn(const char *s, const char *accept) __THROW; -size_t strcspn(const char *s, const char *reject) __THROW; - -char *strpbrk(const char *s, const char *accept) __THROW; -char *strsep(char **stringp, const char *delim) __THROW; - -void* memset(void *s, int c, size_t n) __THROW; - -#undef NULL -#define NULL (void*)0 - -#define bzero(s,n) memset(s,0,n) -#define bcopy(src,dest,n) memmove(dest,src,n) -#define bcmp(a,b,n) memcmp(a,b,n) - -char *strerror(int errnum) __THROW; -char *strsignal(int signum) __THROW; - -char *strtok(char *s, const char *delim) __THROW; -char *strtok_r(char *s, const char *delim, char **ptrptr) __THROW; - -int ffs(int i) __THROW __attribute__((__const__)); - -#endif diff --git a/mdk-stage1/dietlibc/include/strings.h b/mdk-stage1/dietlibc/include/strings.h deleted file mode 100644 index ec947a9b9..000000000 --- a/mdk-stage1/dietlibc/include/strings.h +++ /dev/null @@ -1,2 +0,0 @@ -#warning "your code included obsolescent . Please change that to !" -#include diff --git a/mdk-stage1/dietlibc/include/sys/cdefs.h b/mdk-stage1/dietlibc/include/sys/cdefs.h deleted file mode 100644 index 895bb74b8..000000000 --- a/mdk-stage1/dietlibc/include/sys/cdefs.h +++ /dev/null @@ -1,36 +0,0 @@ -#ifndef _SYS_CDEFS_H -#define _SYS_CDEFS_H - -#define __dietlibc__ - -#ifndef __cplusplus -#define throw () -#define __THROW -#define __BEGIN_DECLS -#define __END_DECLS -#else -#define __THROW throw () -#define __BEGIN_DECLS extern "C" { -#define __END_DECLS } -#endif - -#ifndef __GNUC__ -#define __attribute__(xyz) -#endif - -#define __pure__ -#ifdef __GNUC__ -#if (__GNUC__ > 2) || ((__GNUC__ == 2) && (__GNUC_MINOR__ >= 96)) -#undef __pure__ -#define __pure__ __attribute__ ((__pure__)) -#endif - -#if (__GNUC__ == 2) && (__GNUC_MINOR__ < 95) -#define __restrict__ -#endif - -#endif - -#define __P(x) x - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/file.h b/mdk-stage1/dietlibc/include/sys/file.h deleted file mode 100644 index 93787fd42..000000000 --- a/mdk-stage1/dietlibc/include/sys/file.h +++ /dev/null @@ -1,19 +0,0 @@ -#ifndef _SYS_FILE_H -#define _SYS_FILE_H - -#include - -extern int fcntl(int fd, int cmd, ...) __THROW; -extern int flock(int fd, int operation) __THROW; - -/* Operations for the `flock' call. */ -#define LOCK_SH 1 /* Shared lock. */ -#define LOCK_EX 2 /* Exclusive lock. */ -#define LOCK_UN 8 /* Unlock. */ - -/* Can be OR'd in to one of the above. */ -#define LOCK_NB 4 /* Don't block when locking. */ - - - -#endif /* _SYS_FILE_H */ diff --git a/mdk-stage1/dietlibc/include/sys/io.h b/mdk-stage1/dietlibc/include/sys/io.h deleted file mode 100644 index cce841735..000000000 --- a/mdk-stage1/dietlibc/include/sys/io.h +++ /dev/null @@ -1,41 +0,0 @@ -#ifndef _IO_H -#define _IO_H - -int ioperm(unsigned long from, unsigned long num, int turn_on) __THROW; - -#ifdef __i386__ - -static __inline void -outb (unsigned char value, unsigned short int port) -{ - __asm__ __volatile__ ("outb %b0,%w1": :"a" (value), "Nd" (port)); -} - -static __inline unsigned char -inb (unsigned short int port) -{ - unsigned char _v; - - __asm__ __volatile__ ("inb %w1,%0":"=a" (_v):"Nd" (port)); - return _v; -} - -static __inline unsigned short int -inw (unsigned short int port) -{ - unsigned short _v; - - __asm__ __volatile__ ("inw %w1,%0":"=a" (_v):"Nd" (port)); - return _v; -} - -static __inline void -outw (unsigned short int value, unsigned short int port) -{ - __asm__ __volatile__ ("outw %w0,%w1": :"a" (value), "Nd" (port)); - -} - -#endif - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/ioctl.h b/mdk-stage1/dietlibc/include/sys/ioctl.h deleted file mode 100644 index fca1aeeab..000000000 --- a/mdk-stage1/dietlibc/include/sys/ioctl.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef _IOCTL_H -#define _IOCTL_H - -#include -#include -#include - -int ioctl(int d, int request, ...) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/ipc.h b/mdk-stage1/dietlibc/include/sys/ipc.h deleted file mode 100644 index 9184a2a82..000000000 --- a/mdk-stage1/dietlibc/include/sys/ipc.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _SYS_IPC_H -#define _SYS_IPC_H - -#include -#include -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/kd.h b/mdk-stage1/dietlibc/include/sys/kd.h deleted file mode 100644 index 9e9a5152b..000000000 --- a/mdk-stage1/dietlibc/include/sys/kd.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _SYS_KD_H -#define _SYS_KD_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/mman.h b/mdk-stage1/dietlibc/include/sys/mman.h deleted file mode 100644 index dc398ba90..000000000 --- a/mdk-stage1/dietlibc/include/sys/mman.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef _SYS_MMAN_H -#define _SYS_MMAN_H - -#include -#include -#include -#include - -#ifndef PAGE_SIZE -#warning PAGE_SIZE undefined -#endif - -#define MAP_FAILED ((void *) -1) - -extern void *mmap (void *__addr, size_t __len, int __prot, - int __flags, int __fd, off_t __offset); - -extern int munmap (void *__addr, size_t __len) __THROW; -extern int mprotect (void *__addr, size_t __len, int __prot) __THROW; -extern int msync (void *__addr, size_t __len, int __flags) __THROW; -extern void *mremap (void *__addr, size_t __old_len, size_t __new_len, - int __may_move) __THROW; -extern int mincore (void *__start, size_t __len, unsigned char *__vec); - -#ifdef __quad_t -extern void *mmap64 (void *__addr, size_t __len, int __prot, - int __flags, int __fd, off64_t __offset) __THROW; -#endif - -int mlockall(int flags) __THROW; -int munlockall(void) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/mount.h b/mdk-stage1/dietlibc/include/sys/mount.h deleted file mode 100644 index 2e9e86774..000000000 --- a/mdk-stage1/dietlibc/include/sys/mount.h +++ /dev/null @@ -1,19 +0,0 @@ -#ifndef _SYS_MOUNT_H -#define _SYS_MOUNT_H - -#include -#include -#include - -int mount(const char* specialfile, const char* dir, const char* filesystemtype, - unsigned long rwflag, const void * data) __THROW; - -int umount(const char *specialfile) __THROW; - -int umount(const char *dir) __THROW; - -int umount2(const char *specialfile, int mflag) __THROW; - -int umount2(const char *dir, int mflag) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/msg.h b/mdk-stage1/dietlibc/include/sys/msg.h deleted file mode 100644 index ea1e470b6..000000000 --- a/mdk-stage1/dietlibc/include/sys/msg.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef _SYS_MSG_H -#define _SYS_MSG_H - -#include -#include -#include - -extern int msgctl (int msqid, int cmd, struct msqid_ds *buf) __THROW; -extern int msgget (key_t key, int msgflg) __THROW; -extern int msgrcv (int msqid, void *msgp, size_t msgsz, long int msgtyp, int msgflg) __THROW; -extern int msgsnd (int msqid, const void *msgp, size_t msgsz, int msgflg) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/mtio.h b/mdk-stage1/dietlibc/include/sys/mtio.h deleted file mode 100644 index e70663407..000000000 --- a/mdk-stage1/dietlibc/include/sys/mtio.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _SYS_MTIO_H -#define _SYS_MTIO_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/param.h b/mdk-stage1/dietlibc/include/sys/param.h deleted file mode 100644 index 05f4d40e2..000000000 --- a/mdk-stage1/dietlibc/include/sys/param.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _SYS_PARAM_H -#define _SYS_PARAM_H - -#include - -#define MAXPATHLEN PATH_MAX - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/poll.h b/mdk-stage1/dietlibc/include/sys/poll.h deleted file mode 100644 index adce26687..000000000 --- a/mdk-stage1/dietlibc/include/sys/poll.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef _SYS_POLL_H -#define _SYS_POLL_H - -#include - -#include - -extern int poll(struct pollfd *ufds, unsigned int nfds, int timeout) __THROW; - - -#endif /* _SYS_POLL_H */ diff --git a/mdk-stage1/dietlibc/include/sys/ptrace.h b/mdk-stage1/dietlibc/include/sys/ptrace.h deleted file mode 100644 index 9dd730bc6..000000000 --- a/mdk-stage1/dietlibc/include/sys/ptrace.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef _SYS_PTRACE_H -#define _SYS_PTRACE_H - -#include - -#include - -extern long int ptrace (int request, ...) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/reboot.h b/mdk-stage1/dietlibc/include/sys/reboot.h deleted file mode 100644 index ba58d296a..000000000 --- a/mdk-stage1/dietlibc/include/sys/reboot.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _SYS_REBOOT_H -#define _SYS_REBOOT_H - -#include - -/* Reboot or halt the system. */ -int reboot (int flag, void *arg); - -#endif /* _SYS_REBOOT_H */ diff --git a/mdk-stage1/dietlibc/include/sys/resource.h b/mdk-stage1/dietlibc/include/sys/resource.h deleted file mode 100644 index 442434cd1..000000000 --- a/mdk-stage1/dietlibc/include/sys/resource.h +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef _SYS_RESOURCE_H -#define _SYS_RESOURCE_H - -#include -#include - -int getpriority(int which, int who) __THROW; -int setpriority(int which, int who, int prio) __THROW; - -int getrlimit (int resource, struct rlimit *rlim); -int getrusage (int who, struct rusage *usage); -int setrlimit (int resource, const struct rlimit *rlim); - -typedef unsigned long rlim_t; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/select.h b/mdk-stage1/dietlibc/include/sys/select.h deleted file mode 100644 index e69de29bb..000000000 diff --git a/mdk-stage1/dietlibc/include/sys/sem.h b/mdk-stage1/dietlibc/include/sys/sem.h deleted file mode 100644 index cc182649c..000000000 --- a/mdk-stage1/dietlibc/include/sys/sem.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef _SYS_SEM_H -#define _SYS_SEM_H - -#include -#include - -extern int semget( key_t key, int nsems, int semflg) __THROW; -extern int semctl(int semid, int semnum, int cmd, union semun arg) __THROW; -extern int semop(int semid, struct sembuf *sops, unsigned nsops) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/sendfile.h b/mdk-stage1/dietlibc/include/sys/sendfile.h deleted file mode 100644 index 2e0c04add..000000000 --- a/mdk-stage1/dietlibc/include/sys/sendfile.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _SYS_SENDFILE_H -#define _SYS_SENDFILE_H - -#include - -extern ssize_t sendfile (int __out_fd, int __in_fd, off_t *offset, - size_t __count) __THROW; - -#endif /* sys/sendfile.h */ diff --git a/mdk-stage1/dietlibc/include/sys/shm.h b/mdk-stage1/dietlibc/include/sys/shm.h deleted file mode 100644 index c27f5ddcf..000000000 --- a/mdk-stage1/dietlibc/include/sys/shm.h +++ /dev/null @@ -1,17 +0,0 @@ -#ifndef _SYS_SHM_H -#define _SYS_SHM_H - -#include -#include -#include - -#ifndef PAGE_SIZE -#define PAGE_SIZE getpagesize() -#endif - -extern int shmget(key_t key, int size, int shmflg) __THROW; -extern void *shmat(int shmid, const void *shmaddr, int shmflg) __THROW; -extern int shmdt (const void *shmaddr) __THROW; -extern int shmctl(int shmid, int cmd, struct shmid_ds *buf) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/signal.h b/mdk-stage1/dietlibc/include/sys/signal.h deleted file mode 100644 index 2e602dad8..000000000 --- a/mdk-stage1/dietlibc/include/sys/signal.h +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/mdk-stage1/dietlibc/include/sys/socket.h b/mdk-stage1/dietlibc/include/sys/socket.h deleted file mode 100644 index a1435501c..000000000 --- a/mdk-stage1/dietlibc/include/sys/socket.h +++ /dev/null @@ -1,46 +0,0 @@ -#ifndef _SYS_SOCKET_H -#define _SYS_SOCKET_H - -#include -#include -#include - -#ifndef SOCK_DGRAM -/* the Linux kernel headers suck really badly on non-x86 */ -#define SOCK_STREAM 1 /* stream (connection) socket */ -#define SOCK_DGRAM 2 /* datagram (conn.less) socket */ -#define SOCK_RAW 3 /* raw socket */ -#define SOCK_RDM 4 /* reliably-delivered message */ -#define SOCK_SEQPACKET 5 /* sequential packet socket */ -#define SOCK_PACKET 10 /* linux specific way of */ -#endif - -struct sockaddr_storage { - char __tmp[sizeof(struct sockaddr)]; -}; - -int socket(int domain, int type, int protocol) __THROW; -int accept(int s, struct sockaddr *addr, socklen_t *addrlen) __THROW; -int connect(int sockfd, const struct sockaddr *serv_addr, socklen_t addrlen) __THROW; -int bind(int sockfd, struct sockaddr *my_addr, socklen_t addrlen) __THROW; -int recv(int s, void *buf, size_t len, int flags) __THROW; -int recvfrom(int s, void *buf, size_t len, int flags, struct sockaddr *from, socklen_t *fromlen) __THROW; -int recvmsg(int s, struct msghdr *msg, int flags) __THROW; -int send(int s, const void *msg, size_t len, int flags) __THROW; -int sendto(int s, const void *msg, size_t len, int flags, const struct sockaddr *to, socklen_t tolen) __THROW; -int sendmsg(int s, const struct msghdr *msg, int flags) __THROW; - -int getpeername(int s, struct sockaddr *name, socklen_t *namelen) __THROW; -int getsockname(int s , struct sockaddr * name , socklen_t * namelen) __THROW; - -int getsockopt(int s, int level, int optname, void *optval, socklen_t *optlen) __THROW; -int setsockopt(int s, int level, int optname, const void *optval, socklen_t optlen) __THROW; - -int listen(int s, int backlog) __THROW; - -#define SHUT_RD 0 -#define SHUT_WR 1 -#define SHUT_RDWR 2 -int shutdown(int s, int how) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/stat.h b/mdk-stage1/dietlibc/include/sys/stat.h deleted file mode 100644 index 10fddfa42..000000000 --- a/mdk-stage1/dietlibc/include/sys/stat.h +++ /dev/null @@ -1,52 +0,0 @@ -#ifndef _SYS_STAT_H -#define _SYS_STAT_H - -#include -#include - -#include -#include - -#ifndef STAT64_HAS_BROKEN_ST_INO -#define __NO_STAT64 -#endif - -extern int stat(const char *__file, struct stat *__buf) __THROW; -extern int fstat(int __fd, struct stat *__buf) __THROW; -extern int lstat(const char *__file, struct stat *__buf) __THROW; - -#ifdef __NO_STAT64 -#undef _FILE_OFFSET_BITS -#else -extern int stat64(const char *__file, struct stat64 *__buf) __THROW; -extern int fstat64(int __fd, struct stat64 *__buf) __THROW; -extern int lstat64(const char *__file, struct stat64 *__buf) __THROW; -#endif - -#if _FILE_OFFSET_BITS == 64 -#define lstat(file,buf) lstat64(file,buf) -#define fstat(file,buf) fstat64(file,buf) -#define stat stat64 -#endif - -#define major(dev) (((dev)>>8) & 0xff) -#define minor(dev) ((dev) & 0xff) -#define makedev(major, minor) ((((unsigned int) (major)) << 8) | ((unsigned int) (minor))) - -extern int chmod (const char *__file, mode_t __mode) __THROW; - -extern int fchmod (int __fd, mode_t __mode) __THROW; - -extern mode_t umask (mode_t __mask) __THROW; - -extern int mkdir (const char *__path, mode_t __mode) __THROW; - -extern int mknod (const char *__path, mode_t __mode, dev_t __dev) __THROW; - -extern int mkfifo (const char *__path, mode_t __mode) __THROW; - -#define S_IREAD S_IRUSR -#define S_IWRITE S_IWUSR -#define S_IEXEC S_IXUSR - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/syscall.h b/mdk-stage1/dietlibc/include/sys/syscall.h deleted file mode 100644 index 5d6b5a4ad..000000000 --- a/mdk-stage1/dietlibc/include/sys/syscall.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef _SYSCALL_H -#define _SYSCALL_H - -#include - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/sysinfo.h b/mdk-stage1/dietlibc/include/sys/sysinfo.h deleted file mode 100644 index 5f059d469..000000000 --- a/mdk-stage1/dietlibc/include/sys/sysinfo.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _SYS_SYSINFO_H -#define _SYS_SYSINFO_H - -#include -#include - -int sysinfo(struct sysinfo *info) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/syslog.h b/mdk-stage1/dietlibc/include/sys/syslog.h deleted file mode 100644 index 91bf0d1fa..000000000 --- a/mdk-stage1/dietlibc/include/sys/syslog.h +++ /dev/null @@ -1,102 +0,0 @@ -#ifndef _SYS_SYSLOG_H -#define _SYS_SYSLOG_H 1 - -#include -#include - -#define _PATH_LOG "/dev/log" - -/* - * priorities/facilities are encoded into a single 32-bit quantity, where the - * bottom 3 bits are the priority (0-7) and the top 28 bits are the facility - * (0-big number). Both the priorities and the facilities map roughly - * one-to-one to strings in the syslogd(8) source code. This mapping is - * included in this file. - * - * priorities (these are ordered) - */ -#define LOG_EMERG 0 /* system is unusable */ -#define LOG_ALERT 1 /* action must be taken immediately */ -#define LOG_CRIT 2 /* critical conditions */ -#define LOG_ERR 3 /* error conditions */ -#define LOG_WARNING 4 /* warning conditions */ -#define LOG_NOTICE 5 /* normal but significant condition */ -#define LOG_INFO 6 /* informational */ -#define LOG_DEBUG 7 /* debug-level messages */ - -#define LOG_PRIMASK 0x07 /* mask to extract priority part (internal) */ - /* extract priority */ -#define LOG_PRI(p) ((p) & LOG_PRIMASK) -#define LOG_MAKEPRI(fac, pri) (((fac) << 3) | (pri)) - -/* facility codes */ -#define LOG_KERN (0<<3) /* kernel messages */ -#define LOG_USER (1<<3) /* random user-level messages */ -#define LOG_MAIL (2<<3) /* mail system */ -#define LOG_DAEMON (3<<3) /* system daemons */ -#define LOG_AUTH (4<<3) /* security/authorization messages */ -#define LOG_SYSLOG (5<<3) /* messages generated internally by syslogd */ -#define LOG_LPR (6<<3) /* line printer subsystem */ -#define LOG_NEWS (7<<3) /* network news subsystem */ -#define LOG_UUCP (8<<3) /* UUCP subsystem */ -#define LOG_CRON (9<<3) /* clock daemon */ -#define LOG_AUTHPRIV (10<<3) /* security/authorization messages (private) */ -#define LOG_FTP (11<<3) /* ftp daemon */ - - /* other codes through 15 reserved for system use */ -#define LOG_LOCAL0 (16<<3) /* reserved for local use */ -#define LOG_LOCAL1 (17<<3) /* reserved for local use */ -#define LOG_LOCAL2 (18<<3) /* reserved for local use */ -#define LOG_LOCAL3 (19<<3) /* reserved for local use */ -#define LOG_LOCAL4 (20<<3) /* reserved for local use */ -#define LOG_LOCAL5 (21<<3) /* reserved for local use */ -#define LOG_LOCAL6 (22<<3) /* reserved for local use */ -#define LOG_LOCAL7 (23<<3) /* reserved for local use */ - -#define LOG_NFACILITIES 24 /* current number of facilities */ -#define LOG_FACMASK 0x03f8 /* mask to extract facility part */ - /* facility of pri */ -#define LOG_FAC(p) (((p) & LOG_FACMASK) >> 3) - -/* - * arguments to setlogmask. - */ -#define LOG_MASK(pri) (1 << (pri)) /* mask for one priority */ -#define LOG_UPTO(pri) ((1 << ((pri)+1)) - 1) /* all priorities through pri */ - -/* - * Option flags for openlog. - * - * LOG_ODELAY no longer does anything. - * LOG_NDELAY is the inverse of what it used to be. - */ -#define LOG_PID 0x01 /* log the pid with each message */ -#define LOG_CONS 0x02 /* log on the console if errors in sending */ -#define LOG_ODELAY 0x04 /* delay open until first syslog() (default) */ -#define LOG_NDELAY 0x08 /* don't delay open */ -#define LOG_NOWAIT 0x10 /* don't wait for console forks: DEPRECATED */ -#define LOG_PERROR 0x20 /* log to stderr as well */ - -/* Open connection to system logger. */ -/* against the glibc-routine ident has not to be const ! */ -/* instead ident is limited to 80 characters ! */ -void openlog (const char *ident, int option, int facility); - -void closelog (void) __THROW; - -int setlogmask (int mask) __THROW; - -void syslog (int priority, const char *format, ...) __THROW; - -void vsyslog (int priority, const char *format, va_list arg_ptr) __THROW; - -/* yuck yuck yuck, only needed for syslogd. */ -typedef struct _code { - char *c_name; - int c_val; -} CODE; - -extern CODE prioritynames[]; -extern CODE facilitynames[]; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/time.h b/mdk-stage1/dietlibc/include/sys/time.h deleted file mode 100644 index 11144f57b..000000000 --- a/mdk-stage1/dietlibc/include/sys/time.h +++ /dev/null @@ -1,46 +0,0 @@ -#ifndef _SYS_TIME_H -#define _SYS_TIME_H 1 - -#include - -#include -#include - -#if defined __USE_GNU || defined __USE_BSD -typedef struct timezone *__timezone_ptr_t; -#else -typedef void *__timezone_ptr_t; -#endif - -int getitimer(int which, struct itimerval *value) __THROW; -int setitimer(int which, const struct itimerval *value, struct itimerval *ovalue) __THROW; - -int gettimeofday(struct timeval *tv, struct timezone *tz) __THROW; -int settimeofday(const struct timeval *tv , const struct timezone *tz) __THROW; - -extern int adjtime (const struct timeval *__delta, - struct timeval *__olddelta) __THROW; - -struct tm -{ - int tm_sec; /* Seconds. [0-60] (1 leap second) */ - int tm_min; /* Minutes. [0-59] */ - int tm_hour; /* Hours. [0-23] */ - int tm_mday; /* Day. [1-31] */ - int tm_mon; /* Month. [0-11] */ - int tm_year; /* Year - 1900. */ - int tm_wday; /* Day of week. [0-6] */ - int tm_yday; /* Days in year.[0-365] */ - int tm_isdst; /* DST. [-1/0/1]*/ - - long int tm_gmtoff; /* Seconds east of UTC. */ - const char *tm_zone; /* Timezone abbreviation. */ -}; - -struct tm* gmtime(const time_t *t) __THROW; -struct tm* gmtime_r(const time_t *t, struct tm *r) __THROW; - -struct tm* localtime(const time_t *t) __THROW; -struct tm* localtime_r(const time_t *t, struct tm *r) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/times.h b/mdk-stage1/dietlibc/include/sys/times.h deleted file mode 100644 index 72ec62fec..000000000 --- a/mdk-stage1/dietlibc/include/sys/times.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _SYS_TIMES_H -#define _SYS_TIMES_H - -#include - -clock_t times(struct tms *buf); - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/types.h b/mdk-stage1/dietlibc/include/sys/types.h deleted file mode 100644 index 34dbaa9f1..000000000 --- a/mdk-stage1/dietlibc/include/sys/types.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef _SYS_TYPES_H -#define _SYS_TYPES_H - -#include -#include -#include - -#ifdef __GNUC__ -#define __quad_t __quad_t -typedef long long int __quad_t; -typedef unsigned long long int __u_quad_t; -#else -#warning no long long support - no 64 bit file I/O support -typedef long int __quad_t; -typedef unsigned long int __u_quad_t; -#endif - - -#ifdef __quad_t -typedef __quad_t off64_t; -typedef __u_quad_t ino64_t; -typedef __quad_t blkcnt64_t; -#endif - -typedef long int fpos_t; - -#define socklen_t socklen_t -typedef unsigned int socklen_t; - -typedef long int blksize_t; -typedef long int blkcnt_t; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/uio.h b/mdk-stage1/dietlibc/include/sys/uio.h deleted file mode 100644 index d64fd33c9..000000000 --- a/mdk-stage1/dietlibc/include/sys/uio.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _SYS_UIO -#define _SYS_UIO 1 - -#include - -int readv(int filedes, const struct iovec *vector, size_t count); -int writev(int filedes, const struct iovec *vector, size_t count); - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/un.h b/mdk-stage1/dietlibc/include/sys/un.h deleted file mode 100644 index 213d9290e..000000000 --- a/mdk-stage1/dietlibc/include/sys/un.h +++ /dev/null @@ -1,8 +0,0 @@ -#ifndef _SYS_UN_H -#define _SYS_UN_H - -#include - -#include - -#endif /* sys/un.h */ diff --git a/mdk-stage1/dietlibc/include/sys/utsname.h b/mdk-stage1/dietlibc/include/sys/utsname.h deleted file mode 100644 index 37bf6c811..000000000 --- a/mdk-stage1/dietlibc/include/sys/utsname.h +++ /dev/null @@ -1,35 +0,0 @@ -#ifndef _SYS_UTSNAME_H -#define _SYS_UTSNAME_H 1 - -#include - -/* Length of the entries in `struct utsname' is 65. */ -#define _UTSNAME_LENGTH 65 -#define _UTSNAME_NODENAME_LENGTH _UTSNAME_LENGTH - -/* Linux provides as additional information in the `struct utsname' - the name of the current domain. Define _UTSNAME_DOMAIN_LENGTH - to a value != 0 to activate this entry. */ -#define _UTSNAME_DOMAIN_LENGTH _UTSNAME_LENGTH - -struct utsname { - /* Name of the implementation of the operating system. */ - char sysname[_UTSNAME_LENGTH]; - - /* Name of this node on the network. */ - char nodename[_UTSNAME_NODENAME_LENGTH]; - - /* Current release level of this implementation. */ - char release[_UTSNAME_LENGTH]; - /* Current version level of this release. */ - char version[_UTSNAME_LENGTH]; - - /* Name of the hardware type the system is running on. */ - char machine[_UTSNAME_LENGTH]; - - /* Name of the domain of this node on the network. */ - char domainname[_UTSNAME_DOMAIN_LENGTH]; -}; - -extern int uname (struct utsname *__name) __THROW; -#endif diff --git a/mdk-stage1/dietlibc/include/sys/vfs.h b/mdk-stage1/dietlibc/include/sys/vfs.h deleted file mode 100644 index e4740a225..000000000 --- a/mdk-stage1/dietlibc/include/sys/vfs.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef _SYS_VFS_H -#define _SYS_VFS_H - -#include -#include -#include - -int statfs(const char *path, struct statfs *buf) __THROW; -int fstatfs(int fd, struct statfs *buf) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/sys/wait.h b/mdk-stage1/dietlibc/include/sys/wait.h deleted file mode 100644 index eb70112e2..000000000 --- a/mdk-stage1/dietlibc/include/sys/wait.h +++ /dev/null @@ -1,37 +0,0 @@ -#ifndef _SYS_WAIT_H -#define _SYS_WAIT_H - -#include -#include -#include - -/* If WIFEXITED(STATUS), the low-order 8 bits of the status. */ -#define __WEXITSTATUS(status) (((status) & 0xff00) >> 8) -#define WEXITSTATUS __WEXITSTATUS - -/* If WIFSIGNALED(STATUS), the terminating signal. */ -#define __WTERMSIG(status) ((status) & 0x7f) -#define WTERMSIG __WTERMSIG - -/* If WIFSTOPPED(STATUS), the signal that stopped the child. */ -#define __WSTOPSIG(status) __WEXITSTATUS(status) -#define WSTOPSIG __WSTOPSIG - -/* Nonzero if STATUS indicates normal termination. */ -#define WIFEXITED(status) (__WTERMSIG(status) == 0) - -/* Nonzero if STATUS indicates termination by a signal. */ -#define WIFSIGNALED(status) (!WIFSTOPPED(status) && !WIFEXITED(status)) - -/* Nonzero if STATUS indicates the child is stopped. */ -#define WIFSTOPPED(status) (((status) & 0xff) == 0x7f) - - -pid_t wait(int *status) __THROW; -pid_t waitpid(pid_t pid, int *status, int options) __THROW; - -pid_t wait3(int *status, int options, struct rusage *rusage) __THROW; - -pid_t wait4(pid_t pid, int *status, int options, struct rusage *rusage) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/syslog.h b/mdk-stage1/dietlibc/include/syslog.h deleted file mode 100644 index 830b4928a..000000000 --- a/mdk-stage1/dietlibc/include/syslog.h +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/mdk-stage1/dietlibc/include/termios.h b/mdk-stage1/dietlibc/include/termios.h deleted file mode 100644 index f10909c1b..000000000 --- a/mdk-stage1/dietlibc/include/termios.h +++ /dev/null @@ -1,22 +0,0 @@ -#ifndef _TERMIOS_H -#define _TERMIOS_H - -#include -#include - -/* man, the Linux kernel headers suck */ -#define __USE_BSD -#include -#undef __USE_BSD - -pid_t tcgetpgrp(int fd) __THROW; -int tcsetpgrp(int fd, pid_t pgrpid) __THROW; -int tcgetattr(int fd, struct termios *termios_p) __THROW; -int tcsetattr(int fd, int optional_actions, struct termios *termios_p) __THROW; -speed_t cfgetospeed(struct termios *termios_p) __THROW; -int cfsetospeed(struct termios *termios_p, speed_t speed) __THROW; -speed_t cfgetispeed(struct termios *termios_p) __THROW; -int cfsetispeed(struct termios *termios_p, speed_t speed) __THROW; -int tcflush(int fd, int queue_selector) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/time.h b/mdk-stage1/dietlibc/include/time.h deleted file mode 100644 index 827c85b97..000000000 --- a/mdk-stage1/dietlibc/include/time.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef _TIME_H -#define _TIME_H - -#include -#include - -extern int __isleap(int year); - -int nanosleep(const struct timespec *req, struct timespec *rem) __THROW; -unsigned int sleep(unsigned int secs) __THROW; - -time_t mktime(struct tm *timeptr) __THROW __pure__; - -char *asctime(const struct tm *timeptr) __THROW; -char *asctime_r(const struct tm *timeptr, char *buf) __THROW; - -char *ctime(const time_t *timep) __THROW; - -size_t strftime(char *s, size_t max, const char *format, const struct tm *tm) __THROW; -time_t time(time_t *t) __THROW; - -int stime(time_t *t) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/unistd.h b/mdk-stage1/dietlibc/include/unistd.h deleted file mode 100644 index 1a528c0e4..000000000 --- a/mdk-stage1/dietlibc/include/unistd.h +++ /dev/null @@ -1,168 +0,0 @@ -#ifndef _UNISTD_H -#define _UNISTD_H - -#include -#include -#include -#include -#include -#include -#include - -/* Values for the second argument to access. - These may be OR'd together. */ -#define R_OK 4 /* Test for read permission. */ -#define W_OK 2 /* Test for write permission. */ -#define X_OK 1 /* Test for execute permission. */ -#define F_OK 0 /* Test for existence. */ - -/* Test for access to NAME using the real UID and real GID. */ -extern int access (__const char *__name, int __type) __THROW; - -#define SEEK_SET 0 -#define SEEK_CUR 1 -#define SEEK_END 2 - -#define STDIN_FILENO 0 -#define STDOUT_FILENO 1 -#define STDERR_FILENO 2 - -off_t lseek(int fildes, off_t offset, int whence) __THROW; -int llseek(int fildes, unsigned long hi, unsigned long lo, loff_t* result,int whence) __THROW; -#ifndef __NO_STAT64 -loff_t lseek64(int fildes, loff_t offset, int whence) __THROW; -#endif -#if _FILE_OFFSET_BITS == 64 -#define lseek(fildes,offset,whence) lseek64(fildes,offset,whence) -#endif - -int chdir(const char *path) __THROW; -int fchdir(int fd) __THROW; -int mkdir(const char *pathname, mode_t mode) __THROW; -int rmdir(const char *pathname) __THROW; -char *getcwd(char *buf, size_t size) __THROW; - -int open(const char* pathname,int flags, ...) __THROW; -int open64(const char* pathname,int flags, ...) __THROW; -int creat(const char* pathname,mode_t mode) __THROW; -int creat64(const char* pathname,mode_t mode) __THROW; -int write(int fd,const void* buf,size_t len) __THROW; -int read(int fd,void* buf,size_t len) __THROW; -int close(int fd) __THROW; - -int unlink(const char *pathname) __THROW; - -int pread(int fd, void *buf, size_t count, off_t offset); -int pwrite(int fd, const void *buf, size_t count, off_t offset); - -int execve(const char *filename, char *const argv [], char *const envp[]) __THROW; -int execlp(const char *file, const char *arg, ...) __THROW; -int execv(const char *path, char *const argv[]) __THROW; -int execvp(const char *file, char *const argv[]) __THROW; -int execl(const char *path, ...) __THROW; - -pid_t getpid(void) __attribute__((__const__)) __THROW; -pid_t getppid(void) __THROW; -int kill(pid_t pid, int sig) __THROW; - -int setpgid (pid_t pid,pid_t pgid) __THROW; -pid_t getpgid (pid_t pid) __THROW; -int setpgrp (void) __THROW; -pid_t getpgrp (void) __THROW; -pid_t setsid (void) __THROW; -int dup (int oldfd) __THROW; -int dup2 (int oldfd,int newfd) __THROW; - -int mknod(const char *pathname, mode_t mode, dev_t dev) __THROW; - -int getdents(unsigned int fd, struct dirent *dirp, unsigned int count) __THROW; -int getdents64(unsigned int fd, struct dirent64 *dirp, unsigned int count) __THROW; - -pid_t fork(void) __THROW; -pid_t vfork(void) __THROW; - -int readlink(const char *path, char *buf, size_t bufsiz) __THROW; -int symlink(const char *oldpath, const char *newpath) __THROW; -int link(const char *oldpath, const char *newpath) __THROW; - -int chown(const char *path, uid_t owner, gid_t group) __THROW; -int fchown(int fd, uid_t owner, gid_t group) __THROW; -int lchown(const char *path, uid_t owner, gid_t group) __THROW; - -int fsync(int fd) __THROW; - -int pipe(int filedes[2]) __THROW; - -char *ttyname (int desc) __THROW; - -int brk(void *end_data_segment) __THROW; -void *sbrk(ptrdiff_t increment) __THROW; - -int gethostname(char *name, size_t len) __THROW; -int sethostname(const char *name, size_t len) __THROW; - -void usleep(unsigned long usec) __THROW; -unsigned int sleep(unsigned int seconds) __THROW; - -unsigned int alarm(unsigned int seconds) __THROW; -int sync(void) __THROW; - -int isatty(int desc) __THROW; - -void _exit(int status) __THROW __attribute__((noreturn)); - -extern int daemon (int nochdir,int noclose) __THROW; - -#if _FILE_OFFSET_BITS == 64 -#define open open64 -#define creat creat64 -#endif - -extern char* getlogin(void) __THROW; -/* warning: the diet libc getlogin() simply returns getenv("LOGNAME") */ - -int chroot(const char *path) __THROW; - -uid_t getuid(void) __THROW; -uid_t geteuid(void) __THROW; -gid_t getgid(void) __THROW; -gid_t getegid(void) __THROW; -int setuid(uid_t uid) __THROW; -/* int seteuid(uid_t uid) __THROW; */ -int setgid(gid_t gid) __THROW; -/* int setegid(gid_t gid) __THROW; */ -int setregid(gid_t rgid, gid_t egid) __THROW; -int setreuid(uid_t ruid, uid_t euid) __THROW; -#define seteuid(euid) setreuid(-1,euid) -#define setegid(egid) setregid(-1,egid) - -int rename(const char *oldpath, const char *newpath) __THROW; -int ftruncate(int fd, off_t length) __THROW; - -int mkstemp(char *Template) __THROW; - -int select(int n, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, struct timeval *timeout) __THROW; - -int nice(int inc) __THROW; - -extern char *__environ[]; - -char *crypt(const char *key, const char *salt) __THROW; -void encrypt(char block[64], int edflag) __THROW; -void setkey(const char *key) __THROW; - -size_t getpagesize(void) __attribute__((__const__)) __THROW; - -int getdomainname(char *name, size_t len) __THROW; -int setdomainname(const char *name, size_t len) __THROW; - -int getgroups(int size, gid_t list[]) __THROW; - -/* warning: linux specific: */ -int _sysctl(struct __sysctl_args *args) __THROW; -int sendfile(int out_fd, int in_fd, off_t *offset, size_t count) __THROW; - -int getdtablesize(void) __THROW; -char *getpass(const char * prompt) __THROW; - -#endif diff --git a/mdk-stage1/dietlibc/include/utime.h b/mdk-stage1/dietlibc/include/utime.h deleted file mode 100644 index 41674f379..000000000 --- a/mdk-stage1/dietlibc/include/utime.h +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef _UTIME_H -#define _UTIME_H - -#include -#include -#include - -struct utimbuf { - time_t actime; /* access time */ - time_t modtime; /* modification time */ -}; - -int utime(const char *filename, struct utimbuf *buf) __THROW; - - -#endif diff --git a/mdk-stage1/dietlibc/include/utmp.h b/mdk-stage1/dietlibc/include/utmp.h deleted file mode 100644 index 2946be921..000000000 --- a/mdk-stage1/dietlibc/include/utmp.h +++ /dev/null @@ -1,73 +0,0 @@ -#ifndef _UTMP_H -#define _UTMP_H - -#include -#include -#include - -#define UT_LINESIZE 32 -#define UT_NAMESIZE 32 -#define UT_HOSTSIZE 256 - -#define _PATH_UTMP "/var/run/utmp" -#define _PATH_WTMP "/var/log/wtmp" - -/* The structure describing an entry in the database of - previous logins. */ -struct lastlog - { - time_t ll_time; - char ll_line[UT_LINESIZE]; - char ll_host[UT_HOSTSIZE]; - }; - -/* The structure describing the status of a terminated process. This - type is used in `struct utmp' below. */ -struct exit_status - { - short int e_termination; /* Process termination status. */ - short int e_exit; /* Process exit status. */ - }; - -/* The structure describing an entry in the user accounting database. */ -struct utmp -{ - short int ut_type; /* Type of login. */ - pid_t ut_pid; /* Process ID of login process. */ - char ut_line[UT_LINESIZE]; /* Devicename. */ - char ut_id[4]; /* Inittab ID. */ - char ut_user[UT_NAMESIZE]; /* Username. */ - char ut_host[UT_HOSTSIZE]; /* Hostname for remote login. */ -#define ut_name ut_host - struct exit_status ut_exit; /* Exit status of a process marked - as DEAD_PROCESS. */ - long int ut_session; /* Session ID, used for windowing. */ - struct timeval ut_tv; /* Time entry was made. */ - int32_t ut_addr_v6[4]; /* Internet address of remote host. */ - char __unused[20]; /* Reserved for future use. */ -}; - -/* Values for the `ut_type' field of a `struct utmp'. */ -#define EMPTY 0 /* No valid user accounting information. */ - -#define RUN_LVL 1 /* The system's runlevel. */ -#define BOOT_TIME 2 /* Time of system boot. */ -#define NEW_TIME 3 /* Time after system clock changed. */ -#define OLD_TIME 4 /* Time when system clock changed. */ - -#define INIT_PROCESS 5 /* Process spawned by the init process. */ -#define LOGIN_PROCESS 6 /* Session leader of a logged in user. */ -#define USER_PROCESS 7 /* Normal process. */ -#define DEAD_PROCESS 8 /* Terminated process. */ - -#define ACCOUNTING 9 - -/* Tell the user that we have a modern system with UT_HOST, UT_PID, - UT_TYPE, UT_ID and UT_TV fields. */ -#define _HAVE_UT_TYPE 1 -#define _HAVE_UT_PID 1 -#define _HAVE_UT_ID 1 -#define _HAVE_UT_TV 1 -#define _HAVE_UT_HOST 1 - -#endif -- cgit v1.2.1