os_unix: add #include for libuv
os_unix: switch to libuv chdir() function
os_unix: use libuv total memory function
move libuv functions to os.c and io.c module

Despite being an io library, the functions currently implemented with
libuv include some non-I/O tasks like getting the total amount of
memory.