makefiles and several changes to the environments