add script and modify kernel Makefile