add missing Makefile, update .gitignore, make build_detect_platform executable