Add configure checks for whether netinet/in.h is available or not
Add configure checks for sys/socket.h
Some more configure checks for headers