REORG: sock: start to move some generic socket code to sock.c

The new file sock.c will contain generic code for standard sockets
relying on file descriptors. We currently have way too much duplication
between proto_uxst, proto_tcp, proto_sockpair and proto_udp.

For now only get_src, get_dst and sock_create_server_socket were moved,
and are used where appropriate.
diff --git a/Makefile b/Makefile
index 2372af2..7649998 100644
--- a/Makefile
+++ b/Makefile
@@ -820,7 +820,7 @@
        src/eb64tree.o src/dict.o src/shctx.o src/ebimtree.o                   \
        src/eb32tree.o src/ebtree.o src/dgram.o src/proto_udp.o                \
        src/hpack-huff.o src/cfgparse-tcp.o src/base64.o src/version.o         \
-       src/cfgparse-unix.o
+       src/cfgparse-unix.o src/sock.o
 
 ifneq ($(TRACE),)
 OBJS += src/calltrace.o