BSD 4_2 development
authorCSRG <csrg@ucbvax.Berkeley.EDU>
Sun, 25 Sep 1983 12:54:17 +0000 (04:54 -0800)
committerCSRG <csrg@ucbvax.Berkeley.EDU>
Sun, 25 Sep 1983 12:54:17 +0000 (04:54 -0800)
Work on file usr/include/math.h
Work on file usr/include/mp.h
Work on file usr/include/mtab.h
Work on file usr/include/netdb.h
Work on file usr/include/nlist.h
Work on file usr/include/pwd.h

Synthesized-from: CSRG/cd1/4.2

usr/include/math.h [new file with mode: 0644]
usr/include/mp.h [new file with mode: 0644]
usr/include/mtab.h [new file with mode: 0644]
usr/include/netdb.h [new file with mode: 0644]
usr/include/nlist.h [new file with mode: 0644]
usr/include/pwd.h [new file with mode: 0644]

diff --git a/usr/include/math.h b/usr/include/math.h
new file mode 100644 (file)
index 0000000..a0668c3
--- /dev/null
@@ -0,0 +1,11 @@
+/*     math.h  4.1     83/05/03        */
+
+extern double fabs(), floor(), ceil(), fmod(), ldexp(), frexp();
+extern double sqrt(), hypot(), atof();
+extern double sin(), cos(), tan(), asin(), acos(), atan(), atan2();
+extern double exp(), log(), log10(), pow();
+extern double sinh(), cosh(), tanh();
+extern double gamma();
+extern double j0(), j1(), jn(), y0(), y1(), yn();
+
+#define HUGE   1.701411733192644270e38
diff --git a/usr/include/mp.h b/usr/include/mp.h
new file mode 100644 (file)
index 0000000..749b723
--- /dev/null
@@ -0,0 +1,35 @@
+/*     mp.h    4.2     83/07/01        */
+
+#define MINT struct mint
+MINT
+{      int len;
+       short *val;
+};
+#define FREE(x) {if(x.len!=0) {free((char *)x.val); x.len=0;}}
+#ifndef DBG
+#define shfree(u) free((char *)u)
+#else
+#include <stdio.h>
+#define shfree(u) { if(dbg) fprintf(stderr, "free %o\n", u); free((char *)u);}
+extern int dbg;
+#endif
+#ifndef vax
+struct half
+{      short high;
+       short low;
+};
+#else
+struct half
+{      short low;
+       short high;
+};
+#endif
+extern MINT *itom();
+extern short *xalloc();
+
+#ifdef lint
+extern xv_oid;
+#define VOID xv_oid =
+#else
+#define VOID
+#endif
diff --git a/usr/include/mtab.h b/usr/include/mtab.h
new file mode 100644 (file)
index 0000000..28d86bd
--- /dev/null
@@ -0,0 +1,10 @@
+/*     mtab.h  4.4     83/05/28        */
+
+/*
+ * Mounted device accounting file.
+ */
+struct mtab {
+       char    m_path[32];             /* mounted on pathname */
+       char    m_dname[32];            /* block device pathname */
+       char    m_type[4];              /* read-only, quotas */
+};
diff --git a/usr/include/netdb.h b/usr/include/netdb.h
new file mode 100644 (file)
index 0000000..cddd230
--- /dev/null
@@ -0,0 +1,44 @@
+/*     %M%     %I%     %E%     */
+/*
+ * Structures returned by network
+ * data base library.  All addresses
+ * are supplied in host order, and
+ * returned in network order (suitable
+ * for use in system calls).
+ */
+struct hostent {
+       char    *h_name;        /* official name of host */
+       char    **h_aliases;    /* alias list */
+       int     h_addrtype;     /* host address type */
+       int     h_length;       /* length of address */
+       char    *h_addr;        /* address */
+};
+
+/*
+ * Assumption here is that a network number
+ * fits in 32 bits -- probably a poor one.
+ */
+struct netent {
+       char    *n_name;        /* official name of net */
+       char    **n_aliases;    /* alias list */
+       int     n_addrtype;     /* net address type */
+       int     n_net;          /* network # */
+};
+
+struct servent {
+       char    *s_name;        /* official service name */
+       char    **s_aliases;    /* alias list */
+       int     s_port;         /* port # */
+       char    *s_proto;       /* protocol to use */
+};
+
+struct protoent {
+       char    *p_name;        /* official protocol name */
+       char    **p_aliases;    /* alias list */
+       int     p_proto;        /* protocol # */
+};
+
+struct hostent *gethostbyname(), *gethostbyaddr(), *gethostent();
+struct netent  *getnetbyname(), *getnetbyaddr(), *getnetent();
+struct servent *getservbyname(), *getservbyport(), *getservent();
+struct protoent        *getprotobyname(), *getprotobynumber(), *getprotoent();
diff --git a/usr/include/nlist.h b/usr/include/nlist.h
new file mode 100644 (file)
index 0000000..1adfbed
--- /dev/null
@@ -0,0 +1,40 @@
+/*     nlist.h 4.1     83/05/03        */
+
+/*
+ * Format of a symbol table entry; this file is included by <a.out.h>
+ * and should be used if you aren't interested the a.out header
+ * or relocation information.
+ */
+struct nlist {
+       char    *n_name;        /* for use when in-core */
+       unsigned char n_type;   /* type flag, i.e. N_TEXT etc; see below */
+       char    n_other;        /* unused */
+       short   n_desc;         /* see <stab.h> */
+       unsigned long n_value;  /* value of this symbol (or sdb offset) */
+};
+#define        n_hash  n_desc          /* used internally by ld */
+
+/*
+ * Simple values for n_type.
+ */
+#define        N_UNDF  0x0             /* undefined */
+#define        N_ABS   0x2             /* absolute */
+#define        N_TEXT  0x4             /* text */
+#define        N_DATA  0x6             /* data */
+#define        N_BSS   0x8             /* bss */
+#define        N_COMM  0x12            /* common (internal to ld) */
+#define        N_FN    0x1f            /* file name symbol */
+
+#define        N_EXT   01              /* external bit, or'ed in */
+#define        N_TYPE  0x1e            /* mask for all the type bits */
+
+/*
+ * Sdb entries have some of the N_STAB bits set.
+ * These are given in <stab.h>
+ */
+#define        N_STAB  0xe0            /* if any of these bits set, a SDB entry */
+
+/*
+ * Format for namelist values.
+ */
+#define        N_FORMAT        "%08x"
diff --git a/usr/include/pwd.h b/usr/include/pwd.h
new file mode 100644 (file)
index 0000000..6954fd7
--- /dev/null
@@ -0,0 +1,15 @@
+/*     pwd.h   4.1     83/05/03        */
+
+struct passwd { /* see getpwent(3) */
+       char    *pw_name;
+       char    *pw_passwd;
+       int     pw_uid;
+       int     pw_gid;
+       int     pw_quota;
+       char    *pw_comment;
+       char    *pw_gecos;
+       char    *pw_dir;
+       char    *pw_shell;
+};
+
+struct passwd *getpwent(), *getpwuid(), *getpwnam();