Remove unused source file encode.c
Improve Makefile dependencies