update Makefile
split some util functions into other file