Assignment 7 CS494-unp revised: 10/24/99 Assigned: 10/26/99 Due: 6:00pm 11/3/99 Objective: libraries and hiding the details Points: 20 Description: Build a wrapper library to hide all of the details of TCP and UDP socket setup. Your library should include the readline(), readn(), writen(), err_sys() functions and the following: client: int tcp_connect("host","portorservice") server: int tcp_listen("portorservice") int tcp_accept(int listenfd) client: (use connect()) int udp_connect("host","portorservice") and probably some name/ipaddress resolution function. (Some of you have already been using library-like routines, so if you prefer different wrappers, that is OK.) You need to have a makefile and a .h file for the prototypes of your library functions. Your makefile should use ar and ranlib to create the library (e.g., mynetlib.a) The header file (.h) should include comments describing the various library functions. Test/demonstrate your library by writing a simple TCP echo server and a simple TCP echo client. Describe any other testing that you did with your library. Check error status on ALL network function calls. It's OK just to print an error and exit on errors detected by your library. Check for EINTR where appropriate. Do NOT use any of the Stevens' libraries nor his wrapper include file. Optional: please indicate amount of time required to complete assignment. Use ~dunigan/cs494-unp/494submit to submit your source files and output. See http://www.cs.utk.edu/~dunigan/cs494-unp/policy.txt