Add several more functions, fix makefile