Download and Package script refactored, Makefile bug fixed