Implement memory allocation system calls

Added telos_malloc() and free() system calls, as well as a malloc()
library function (which is just a wrapper for telos_malloc()).
Add memory test program

Also add dispatch/mem.c, which should have been committed before.
Improve makefile

Factor out common dependencies.